linux statusicon: Use app id variable for icon lookup

This commit is contained in:
Hylke Bons 2018-08-05 15:54:41 +01:00
parent b944e9d0af
commit eda316eb3c
2 changed files with 4 additions and 4 deletions

View file

@ -51,13 +51,13 @@ namespace SparkleShare {
if (use_appindicator) {
#if HAVE_APP_INDICATOR
indicator = new Indicator ("sparkleshare", "sparkleshare", (int) IndicatorCategory.ApplicationStatus) {
IconName = "org.sparkleshare.SparkleShare-symbolic",
IconName = UserInterface.APP_ID + "-symbolic",
Status = (int) IndicatorStatus.Active
};
#endif
} else {
this.status_icon = new Gtk.StatusIcon { IconName = "org.sparkleshare.SparkleShare" };
this.status_icon = new Gtk.StatusIcon { IconName = UserInterface.APP_ID };
this.status_icon.Activate += ShowMenu; // Primary mouse button click
this.status_icon.PopupMenu += ShowMenu; // Secondary mouse button click
}
@ -127,7 +127,7 @@ namespace SparkleShare {
this.state_item = new MenuItem (Controller.StateText) { Sensitive = false };
ImageMenuItem folder_item = new SparkleMenuItem ("SparkleShare");
folder_item.Image = new Image (UserInterfaceHelpers.GetIcon ("org.sparkleshare.SparkleShare", 16));
folder_item.Image = new Image (UserInterfaceHelpers.GetIcon (UserInterface.APP_ID, 16));
folder_item.Submenu = new Menu ();
this.menu.Add (this.state_item);

View file

@ -38,7 +38,7 @@ namespace SparkleShare
public string SecondaryTextColor;
public string SecondaryTextColorSelected;
public readonly string APP_ID = "org.sparkleshare.SparkleShare.Nightly";
public static readonly string APP_ID = "org.sparkleshare.SparkleShare.Nightly";
Application application;