]> gitweb.michael.orlitzky.com - xfce4-hdaps.git/blobdiff - panel-plugin/xfce4-hdaps.c
COPYING: update license to AGPL-3.
[xfce4-hdaps.git] / panel-plugin / xfce4-hdaps.c
index 732224c4e5dfe7e65ead2845e38eab56b8c11c82..95f05eb5f90a14b014b94f6db7d496da45a84e07 100644 (file)
@@ -1,21 +1,22 @@
 /*
  * xfce4-hdaps, an XFCE4 panel plugin for the HDAPS system.
  *
- * Copyright Michael Orlitzky
+ * Copyright (C) 2019 Michael Orlitzky
  *
- * http://michael.orlitzky.com/
+ *   http://michael.orlitzky.com/
  *
  * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Affero General Public License for more details:
+ *
+ *   https://www.gnu.org/licenses/agpl-3.0.html
  *
- * http://www.fsf.org/licensing/licenses/gpl.html
  */
 
 #ifdef HAVE_CONFIG_H
@@ -252,7 +253,7 @@ static HdapsPlugin *hdaps_new(XfcePanelPlugin *plugin) {
   /* Make the event box transparent. In newer versions of xfce4-panel
      users can make the panel transparent, so we don't want to stick a
      big opaque box on it. */
-  gtk_event_box_set_visible_window(hdaps->eventbox, FALSE);
+  gtk_event_box_set_visible_window(GTK_EVENT_BOX(hdaps->eventbox), FALSE);
 
   /* Set up the hvbox for the widget, which supports
      both horizontal and vertical (hv) orientations. */
@@ -345,6 +346,9 @@ static gboolean hdaps_size_changed(XfcePanelPlugin *plugin,
     gtk_widget_set_size_request(GTK_WIDGET(plugin), size, -1);
   }
 
+  /* This fixes an issue where the initial icon size is too small. */
+  hdaps_set_icon(hdaps, hdaps->previous_status);
+
   /* We handled the change, so we're supposed to return TRUE. */
   return TRUE;
 }