From 533f7c24e5490b5958165ce5815db495e0bd202c Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Wed, 29 Jan 2014 17:53:26 -0600 Subject: don't load the alarm icon until we need it, which in the case of the desktop greeter is never. --- src/menu.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/menu.cpp b/src/menu.cpp index 44da7b7..4ed0a03 100644 --- a/src/menu.cpp +++ b/src/menu.cpp @@ -51,9 +51,6 @@ protected: m_actions(actions), m_formatter(formatter) { - // preload the alarm icon from click - m_serialized_alarm_icon = create_alarm_icon(); - // initialize the menu create_gmenu(); for (int i=0; i m_formatter; GMenu* m_submenu = nullptr; - GVariant* get_serialized_alarm_icon() { return m_serialized_alarm_icon; } + GVariant* get_serialized_alarm_icon() + { + if (G_UNLIKELY(m_serialized_alarm_icon == nullptr)) + m_serialized_alarm_icon = create_alarm_icon(); + + return m_serialized_alarm_icon; + } private: -- cgit v1.2.3 From 50f1783714c3f2427d8c68c79f2103bb06377abb Mon Sep 17 00:00:00 2001 From: Robert Ancell Date: Tue, 11 Feb 2014 11:59:02 +1300 Subject: Move date/time panel into unity-control-center --- src/CMakeLists.txt | 5 ----- src/actions-live.cpp | 4 ---- 2 files changed, 9 deletions(-) (limited to 'src') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 810e299..2cea786 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -7,11 +7,6 @@ SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -g ${CXX_WARNING_ARGS} ${GCO add_definitions (-DTIMEZONE_FILE="/etc/timezone" -DG_LOG_DOMAIN="Indicator-Datetime") -# let service know how to launch gnome-control-center on the desktop -if (BUILD_PANEL) - add_definitions (-DHAVE_CCPANEL) -endif () - add_library (${SERVICE_LIB} STATIC actions.cpp actions-live.cpp diff --git a/src/actions-live.cpp b/src/actions-live.cpp index c0fd8ff..f510ed1 100644 --- a/src/actions-live.cpp +++ b/src/actions-live.cpp @@ -68,11 +68,7 @@ void LiveActions::open_desktop_settings() } else { -#ifdef HAVE_CCPANEL - execute_command("gnome-control-center indicator-datetime"); -#else execute_command("gnome-control-center datetime"); -#endif } g_free (path); -- cgit v1.2.3