Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(223)

Unified Diff: ui/aura/x11_atom_cache.cc

Issue 10416020: Desktop aura: Put x11 cache in aura, instead of ui/base/x/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix X11AtomCache ownership. Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/aura/x11_atom_cache.cc
diff --git a/ui/base/x/x11_atom_cache.cc b/ui/aura/x11_atom_cache.cc
similarity index 86%
rename from ui/base/x/x11_atom_cache.cc
rename to ui/aura/x11_atom_cache.cc
index 9f16df83d343b7e791d418d0990f92c240b8d090..1ca6d9257bf25157f5f03e0323423b40858abc48 100644
--- a/ui/base/x/x11_atom_cache.cc
+++ b/ui/aura/x11_atom_cache.cc
@@ -2,20 +2,20 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "ui/base/x/x11_atom_cache.h"
+#include "ui/aura/x11_atom_cache.h"
#include <X11/Xatom.h>
#include "base/message_pump_x.h"
-namespace ui {
+namespace aura {
namespace {
// A list of atoms that we'll intern on host creation to save roundtrips to the
// X11 server. Must be kept in sync with AtomCache::AtomName
struct AtomInfo {
- ui::AtomName id;
+ aura::AtomName id;
Daniel Erat 2012/05/21 22:49:43 nit: shouldn't need the aura:: qualifier here
const char* name;
} const kAtomList[] = {
{ ATOM_WM_DELETE_WINDOW, "WM_DELETE_WINDOW" },
@@ -27,15 +27,11 @@ struct AtomInfo {
};
// Our lists need to stay in sync here.
-COMPILE_ASSERT(arraysize(kAtomList) == ui::ATOM_COUNT,
+COMPILE_ASSERT(arraysize(kAtomList) == aura::ATOM_COUNT,
Daniel Erat 2012/05/21 22:49:43 or here
atom_lists_are_same_size);
} // namespace
-X11AtomCache* X11AtomCache::GetInstance() {
- return Singleton<X11AtomCache>::get();
-}
-
::Atom X11AtomCache::GetAtom(AtomName name) const {
std::map<AtomName, ::Atom>::const_iterator it = cached_atoms_.find(name);
DCHECK(it != cached_atoms_.end());
@@ -60,6 +56,4 @@ X11AtomCache::X11AtomCache() {
X11AtomCache::~X11AtomCache() {}
-} // namespace ui
-
-
+} // namespace aura
« ui/aura/aura.gyp ('K') | « ui/aura/x11_atom_cache.h ('k') | ui/base/x/x11_atom_cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698