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

Unified Diff: views/widget/widget_gtk.cc

Issue 5075003: Converts usage of SetProp/GetProp to a map. Even after making sure we (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix gyp files Created 10 years, 1 month 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
« no previous file with comments | « views/widget/widget_gtk.h ('k') | views/widget/widget_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/widget/widget_gtk.cc
diff --git a/views/widget/widget_gtk.cc b/views/widget/widget_gtk.cc
index 5dea13c51aae3631e8cb2e30fcddf85693ffe758..dcb6fb3ecaef1d8d80da0e2862dea593dc6a548e 100644
--- a/views/widget/widget_gtk.cc
+++ b/views/widget/widget_gtk.cc
@@ -32,7 +32,6 @@ namespace {
// g_object data keys to associate a WidgetGtk object to a GtkWidget.
const char* kWidgetKey = "__VIEWS_WIDGET__";
-const wchar_t* kWidgetWideKey = L"__VIEWS_WIDGET__";
// A g_object data key to associate a CompositePainter object to a GtkWidget.
const char* kCompositePainterKey = "__VIEWS_COMPOSITE_PAINTER__";
// A g_object data key to associate the flag whether or not the widget
@@ -803,13 +802,12 @@ const Window* WidgetGtk::GetWindow() const {
return GetWindowImpl(widget_);
}
-void WidgetGtk::SetNativeWindowProperty(const std::wstring& name,
- void* value) {
- g_object_set_data(G_OBJECT(widget_), WideToUTF8(name).c_str(), value);
+void WidgetGtk::SetNativeWindowProperty(const char* name, void* value) {
+ g_object_set_data(G_OBJECT(widget_), name, value);
}
-void* WidgetGtk::GetNativeWindowProperty(const std::wstring& name) {
- return g_object_get_data(G_OBJECT(widget_), WideToUTF8(name).c_str());
+void* WidgetGtk::GetNativeWindowProperty(const char* name) {
+ return g_object_get_data(G_OBJECT(widget_), name);
}
ThemeProvider* WidgetGtk::GetThemeProvider() const {
@@ -1490,7 +1488,7 @@ void WidgetGtk::CreateGtkWidget(GtkWidget* parent, const gfx::Rect& bounds) {
}
// Setting the WidgetKey property to widget_, which is used by
// GetWidgetFromNativeWindow.
- SetNativeWindowProperty(kWidgetWideKey, this);
+ SetNativeWindowProperty(kWidgetKey, this);
}
void WidgetGtk::ConfigureWidgetForTransparentBackground(GtkWidget* parent) {
« no previous file with comments | « views/widget/widget_gtk.h ('k') | views/widget/widget_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698