MCPcopy Create free account
hub / github.com/SFML/SFML / getAtom

Function getAtom

src/SFML/Window/Unix/Display.cpp:128–141  ·  view source on GitHub ↗

///////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

126
127////////////////////////////////////////////////////////////
128Atom getAtom(const std::string& name, bool onlyIfExists)
129{
130 static std::unordered_map<std::string, Atom> atoms;
131
132 if (const auto it = atoms.find(name); it != atoms.end())
133 return it->second;
134
135 const auto display = openDisplay();
136 const Atom atom = XInternAtom(display.get(), name.c_str(), onlyIfExists ? True : False);
137 if (atom)
138 atoms[name] = atom;
139
140 return atom;
141}
142
143} // namespace sf::priv

Callers 15

checkEventFunction · 0.85
WindowImplX11.cppFile · 0.85
ewmhSupportedFunction · 0.85
getEWMHFrameExtentsFunction · 0.85
WindowImplX11Method · 0.85
setTitleMethod · 0.85
setIconMethod · 0.85
grabFocusMethod · 0.85
switchToFullscreenMethod · 0.85
setProtocolsMethod · 0.85
initializeMethod · 0.85
updateLastInputTimeMethod · 0.85

Calls 4

openDisplayFunction · 0.85
findMethod · 0.80
getMethod · 0.80
endMethod · 0.45

Tested by

no test coverage detected