diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/CMakeLists.txt | 19 | ||||
-rw-r--r-- | src/brightness.c | 14 | ||||
-rw-r--r-- | src/dbus-shared.h | 4 | ||||
-rw-r--r-- | src/notifier.c | 10 | ||||
-rw-r--r-- | src/org.ayatana.powerd.xml (renamed from src/com.canonical.powerd.xml) | 2 | ||||
-rw-r--r-- | src/service.c | 18 |
6 files changed, 33 insertions, 34 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8748484..9e537c8 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,7 +1,7 @@ -set (SERVICE_LIB "indicatorpowerservice") -set (SERVICE_EXEC "indicator-power-service") +set (SERVICE_LIB "ayatanaindicatorpowerservice") +set (SERVICE_EXEC "aytana-indicator-power-service") -add_definitions(-DG_LOG_DOMAIN="Indicator-Power") +add_definitions(-DG_LOG_DOMAIN="Ayatana-Indicator-Power") # handwritten sources set(SERVICE_MANUAL_SOURCES @@ -18,17 +18,17 @@ set(SERVICE_MANUAL_SOURCES include(GdbusCodegen) set(SERVICE_GENERATED_SOURCES) add_gdbus_codegen_with_namespace(SERVICE_GENERATED_SOURCES dbus-powerd - com.canonical + org.ayatana Dbus - ${CMAKE_SOURCE_DIR}/src/com.canonical.powerd.xml) + ${CMAKE_SOURCE_DIR}/src/org.ayatana.powerd.xml) add_gdbus_codegen_with_namespace(SERVICE_GENERATED_SOURCES dbus-battery - com.canonical.indicator.power + org.ayatana.indicator.power Dbus - ${CMAKE_SOURCE_DIR}/data/com.canonical.indicator.power.Battery.xml) + ${CMAKE_SOURCE_DIR}/data/org.ayatana.indicator.power.Battery.xml) add_gdbus_codegen_with_namespace(SERVICE_GENERATED_SOURCES dbus-testing - com.canonical.indicator.power + org.ayatana.indicator.power Dbus - ${CMAKE_SOURCE_DIR}/data/com.canonical.indicator.power.Testing.xml) + ${CMAKE_SOURCE_DIR}/data/org.ayatana.indicator.power.Testing.xml) # add the bin dir to our include path so the code can find the generated header files include_directories(${CMAKE_CURRENT_BINARY_DIR}) @@ -53,4 +53,3 @@ add_executable (${SERVICE_EXEC} main.c) set_source_files_properties(${SERVICE_SOURCES} main.c PROPERTIES COMPILE_FLAGS "${C_WARNING_ARGS} -g -std=c99") target_link_libraries (${SERVICE_EXEC} ${SERVICE_LIB} ${SERVICE_DEPS_LIBRARIES} ${GCOV_LIBS}) install (TARGETS ${SERVICE_EXEC} RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_PKGLIBEXECDIR}) - diff --git a/src/brightness.c b/src/brightness.c index eb48515..1f36aca 100644 --- a/src/brightness.c +++ b/src/brightness.c @@ -198,7 +198,7 @@ percentage_to_brightness(IndicatorPowerBrightness * self, double percentage) } /** - * DBus Chatter: com.canonical.powerd + * DBus Chatter: org.ayatana.powerd * * This is used to get default value, and upper and lower bounds, * of the brightness setting @@ -339,7 +339,7 @@ on_powerd_proxy_ready(GObject * source_object G_GNUC_UNUSED, } /** - * DBus Chatter: com.canonical.Unity.Screen + * DBus Chatter: org.ayatana.Unity.Screen * * Used to set the backlight brightness via setUserBrightness */ @@ -374,9 +374,9 @@ set_uscreen_user_brightness(IndicatorPowerBrightness * self, priv_t * p = get_priv(self); g_dbus_connection_call(p->system_bus, - "com.canonical.Unity.Screen", - "/com/canonical/Unity/Screen", - "com.canonical.Unity.Screen", + "org.ayatana.Unity.Screen", + "/org.ayatana.Unity/Screen", + "org.ayatana.Unity.Screen", "setUserBrightness", g_variant_new("(i)", value), NULL, /* no return args */ @@ -463,8 +463,8 @@ indicator_power_brightness_init(IndicatorPowerBrightness * self) dbus_powerd_proxy_new_for_bus (G_BUS_TYPE_SYSTEM, G_DBUS_PROXY_FLAGS_GET_INVALIDATED_PROPERTIES, - "com.canonical.powerd", - "/com/canonical/powerd", + "org.ayatana.powerd", + "/org.ayatana.powerd", p->cancellable, on_powerd_proxy_ready, self); diff --git a/src/dbus-shared.h b/src/dbus-shared.h index bf54034..c87befd 100644 --- a/src/dbus-shared.h +++ b/src/dbus-shared.h @@ -21,8 +21,8 @@ #ifndef DBUS_SHARED_H #define DBUS_SHARED_H -#define BUS_NAME "com.canonical.indicator.power" -#define BUS_PATH "/com/canonical/indicator/power" +#define BUS_NAME "org.ayatana.indicator.power" +#define BUS_PATH "/org/ayatana/indicator/power" #endif /* DBUS_SHARED_H */ diff --git a/src/notifier.c b/src/notifier.c index 4888610..5608662 100644 --- a/src/notifier.c +++ b/src/notifier.c @@ -73,7 +73,7 @@ typedef struct NotifyNotification * notify_notification; GDBusConnection * bus; - DbusBattery * dbus_battery; /* com.canonical.indicator.power.Battery skeleton */ + DbusBattery * dbus_battery; /* org.ayatana.indicator.power.Battery skeleton */ gboolean caps_queried; gboolean actions_supported; @@ -244,10 +244,10 @@ notification_show(IndicatorPowerNotifier * self) if (are_actions_supported(self)) { - notify_notification_set_hint(nn, "x-canonical-snap-decisions", g_variant_new_string("true")); - notify_notification_set_hint(nn, "x-canonical-non-shaped-icon", g_variant_new_string("true")); - notify_notification_set_hint(nn, "x-canonical-private-affirmative-tint", g_variant_new_string("true")); - notify_notification_set_hint(nn, "x-canonical-snap-decisions-timeout", g_variant_new_int32(INT32_MAX)); + notify_notification_set_hint(nn, "x-ayatana-snap-decisions", g_variant_new_string("true")); + notify_notification_set_hint(nn, "x-ayatana-non-shaped-icon", g_variant_new_string("true")); + notify_notification_set_hint(nn, "x-ayatana-private-affirmative-tint", g_variant_new_string("true")); + notify_notification_set_hint(nn, "x-ayatana-snap-decisions-timeout", g_variant_new_int32(INT32_MAX)); notify_notification_set_timeout(nn, NOTIFY_EXPIRES_NEVER); notify_notification_add_action(nn, "dismiss", _("OK"), on_dismiss_clicked, NULL, NULL); notify_notification_add_action(nn, "settings", _("Battery settings"), on_battery_settings_clicked, NULL, NULL); diff --git a/src/com.canonical.powerd.xml b/src/org.ayatana.powerd.xml index b5b4ac4..1d18ca9 100644 --- a/src/com.canonical.powerd.xml +++ b/src/org.ayatana.powerd.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <node name="/"> - <interface name="com.canonical.powerd"> + <interface name="org.ayatana.powerd"> <!-- Properties --> <property name="brightness" type="i" access="readwrite"> diff --git a/src/service.c b/src/service.c index cd0f24e..6bd5959 100644 --- a/src/service.c +++ b/src/service.c @@ -29,8 +29,8 @@ #include "notifier.h" #include "service.h" -#define BUS_NAME "com.canonical.indicator.power" -#define BUS_PATH "/com/canonical/indicator/power" +#define BUS_NAME "org.ayatana.indicator.power" +#define BUS_PATH "/org/ayatana/indicator/power" #define SETTINGS_SHOW_TIME_S "show-time" #define SETTINGS_ICON_POLICY_S "icon-policy" @@ -478,7 +478,7 @@ append_device_to_menu (GMenu * menu, const IndicatorPowerDevice * device, int pr item = g_menu_item_new (label, NULL); g_free (label); - g_menu_item_set_attribute (item, "x-canonical-type", "s", "com.canonical.indicator.basic"); + g_menu_item_set_attribute (item, "x-ayatana-type", "s", "org.ayatana.indicator.basic"); if ((icon = indicator_power_device_get_gicon (device))) { @@ -531,7 +531,7 @@ create_phone_devices_section (IndicatorPowerService * self G_GNUC_UNUSED) menu = g_menu_new (); item = g_menu_item_new (_("Charge level"), "indicator.battery-level"); - g_menu_item_set_attribute (item, "x-canonical-type", "s", "com.canonical.indicator.progress"); + g_menu_item_set_attribute (item, "x-ayatana-type", "s", "org.ayatana.indicator.progress"); g_menu_append_item (menu, item); g_object_unref (item); @@ -552,7 +552,7 @@ create_brightness_menu_item(void) GMenuItem * item; item = g_menu_item_new(NULL, "indicator.brightness"); - g_menu_item_set_attribute(item, "x-canonical-type", "s", "com.canonical.unity.slider"); + g_menu_item_set_attribute(item, "x-ayatana-type", "s", "org.ayatana.unity.slider"); g_menu_item_set_attribute(item, "min-value", "d", 0.0); g_menu_item_set_attribute(item, "max-value", "d", 1.0); @@ -633,7 +633,7 @@ create_phone_settings_section(IndicatorPowerService * self) if (ab_supported) { item = g_menu_item_new(_("Adjust brightness automatically"), "indicator.auto-brightness"); - g_menu_item_set_attribute(item, "x-canonical-type", "s", "com.canonical.indicator.switch"); + g_menu_item_set_attribute(item, "x-ayatana-type", "s", "org.ayatana.indicator.switch"); g_menu_append_item(section, item); g_object_unref(item); } @@ -741,8 +741,8 @@ create_menu (IndicatorPowerService * self, int profile) /* add submenu to the header */ header = g_menu_item_new (NULL, "indicator._header"); - g_menu_item_set_attribute (header, "x-canonical-type", - "s", "com.canonical.indicator.root"); + g_menu_item_set_attribute (header, "x-ayatana-type", + "s", "org.ayatana.indicator.root"); g_menu_item_set_submenu (header, G_MENU_MODEL (submenu)); g_object_unref (submenu); @@ -1176,7 +1176,7 @@ indicator_power_service_init (IndicatorPowerService * self) p->cancellable = g_cancellable_new (); - p->settings = g_settings_new ("com.canonical.indicator.power"); + p->settings = g_settings_new ("org.ayatana.indicator.power"); p->notifier = indicator_power_notifier_new (); |