refactor: simpler sni naming

This commit is contained in:
Alexis
2018-10-26 10:05:54 +02:00
parent 3f269ff463
commit f20441fa92
8 changed files with 55 additions and 60 deletions

View File

@ -19,10 +19,8 @@ class Host {
static void nameVanished(GDBusConnection*, const gchar*, gpointer);
static void proxyReady(GObject*, GAsyncResult*, gpointer);
static void registerHost(GObject*, GAsyncResult*, gpointer);
static void itemRegistered(SnOrgKdeStatusNotifierWatcher*, const gchar*,
gpointer);
static void itemUnregistered(SnOrgKdeStatusNotifierWatcher*, const gchar*,
gpointer);
static void itemRegistered(SnWatcher*, const gchar*, gpointer);
static void itemUnregistered(SnWatcher*, const gchar*, gpointer);
std::tuple<std::string, std::string> getBusNameAndObjectPath(const gchar*);
void addRegisteredItem(const gchar* service);
@ -33,7 +31,7 @@ class Host {
std::string object_path_;
Glib::Dispatcher* dp_;
GCancellable* cancellable_ = nullptr;
SnOrgKdeStatusNotifierWatcher* watcher_ = nullptr;
SnWatcher* watcher_ = nullptr;
};
}

View File

@ -45,7 +45,7 @@ private:
Glib::Dispatcher *dp_;
GCancellable *cancellable_ = nullptr;
SnOrgKdeStatusNotifierItem *proxy_ = nullptr;
SnItem *proxy_ = nullptr;
};
} // namespace waybar::modules::SNI

View File

@ -34,13 +34,13 @@ private:
static void nameVanished(GDBusConnection *connection, const char *name,
gpointer data);
void updateRegisteredItems(SnOrgKdeStatusNotifierWatcher *obj);
void updateRegisteredItems(SnWatcher *obj);
uint32_t bus_name_id_;
uint32_t watcher_id_;
GSList *hosts_ = nullptr;
GSList *items_ = nullptr;
SnOrgKdeStatusNotifierWatcher *watcher_ = nullptr;
SnWatcher *watcher_ = nullptr;
};
} // namespace waybar::modules::SNI