[gnote] Use Glib::RefPtr for cursors in watchers
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Use Glib::RefPtr for cursors in watchers
- Date: Wed, 1 Jun 2011 20:10:46 +0000 (UTC)
commit 9d38a317142b7a89349d2d6f7fd55c856871327d
Author: Aurimas Ä?ernius <aurisc4 gmail com>
Date: Sun May 29 23:04:28 2011 +0300
Use Glib::RefPtr for cursors in watchers
src/watchers.cpp | 8 ++++----
src/watchers.hpp | 6 +++---
2 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/src/watchers.cpp b/src/watchers.cpp
index 20ecf30..cbd53db 100644
--- a/src/watchers.cpp
+++ b/src/watchers.cpp
@@ -1039,14 +1039,14 @@ namespace gnote {
////////////////////////////////////////////////////////////////////////
bool MouseHandWatcher::s_static_inited = false;
- Gdk::Cursor MouseHandWatcher::s_normal_cursor;
- Gdk::Cursor MouseHandWatcher::s_hand_cursor;
+ Glib::RefPtr<Gdk::Cursor> MouseHandWatcher::s_normal_cursor;
+ Glib::RefPtr<Gdk::Cursor> MouseHandWatcher::s_hand_cursor;
void MouseHandWatcher::_init_static()
{
if(!s_static_inited) {
- s_normal_cursor = Gdk::Cursor(Gdk::XTERM);
- s_hand_cursor = Gdk::Cursor(Gdk::HAND2);
+ s_normal_cursor = Gdk::Cursor::create(Gdk::XTERM);
+ s_hand_cursor = Gdk::Cursor::create(Gdk::HAND2);
s_static_inited = true;
}
}
diff --git a/src/watchers.hpp b/src/watchers.hpp
index 95d568a..7c019d1 100644
--- a/src/watchers.hpp
+++ b/src/watchers.hpp
@@ -1,7 +1,7 @@
/*
* gnote
*
- * Copyright (C) 2010 Aurimas Cernius
+ * Copyright (C) 2010-2011 Aurimas Cernius
* Copyright (C) 2009 Hubert Figuiere
*
* This program is free software: you can redistribute it and/or modify
@@ -254,8 +254,8 @@ namespace gnote {
bool on_editor_motion(GdkEventMotion *);
bool m_hovering_on_link;
static bool s_static_inited;
- static Gdk::Cursor s_normal_cursor;
- static Gdk::Cursor s_hand_cursor;
+ static Glib::RefPtr<Gdk::Cursor> s_normal_cursor;
+ static Glib::RefPtr<Gdk::Cursor> s_hand_cursor;
};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]