[geary/wip/geary-inspector: 19/21] Minor code tidy up



commit e428d7b2cb95364481cde242958d6be0da7c37f7
Author: Michael Gratton <mike vee net>
Date:   Sun Apr 7 18:04:07 2019 +1000

    Minor code tidy up

 src/client/components/components-inspector.vala | 4 ++--
 src/client/composer/composer-widget.vala        | 2 --
 src/engine/api/geary-logging.vala               | 8 ++------
 3 files changed, 4 insertions(+), 10 deletions(-)
---
diff --git a/src/client/components/components-inspector.vala b/src/client/components/components-inspector.vala
index 324deaad..3bb4e0c0 100644
--- a/src/client/components/components-inspector.vala
+++ b/src/client/components/components-inspector.vala
@@ -132,7 +132,7 @@ public class Components.Inspector : Gtk.ApplicationWindow {
                 logs_store.insert(out iter, index++);
                 logs_store.set_value(iter, COL_MESSAGE, logs.format());
             }
-            logs = logs.get_next();
+            logs = logs.next;
         }
 
         this.logs_filter = new Gtk.TreeModelFilter(logs_store, null);
@@ -208,7 +208,7 @@ public class Components.Inspector : Gtk.ApplicationWindow {
             Geary.Logging.Record? logs = this.first_pending;
             while (logs != null) {
                 append_record(logs);
-                logs = logs.get_next();
+                logs = logs.next;
             }
             this.first_pending = null;
         }
diff --git a/src/client/composer/composer-widget.vala b/src/client/composer/composer-widget.vala
index f3541f9f..e4e6d406 100644
--- a/src/client/composer/composer-widget.vala
+++ b/src/client/composer/composer-widget.vala
@@ -135,8 +135,6 @@ public class ComposerWidget : Gtk.EventBox, Geary.BaseInterface {
         {ACTION_SHOW_EXTENDED,            on_toggle_action,        null,  "false",  on_show_extended_toggled 
  },
     };
 
-    public static Gee.MultiMap<string, string> action_accelerators = new Gee.HashMultiMap<string, string>();
-
     public static void add_window_accelerators(GearyApplication application) {
         application.add_window_accelerators(ACTION_CLOSE, { "Escape" } );
         application.add_window_accelerators(ACTION_CUT, { "<Ctrl>x" } );
diff --git a/src/engine/api/geary-logging.vala b/src/engine/api/geary-logging.vala
index 6c22992e..79345713 100644
--- a/src/engine/api/geary-logging.vala
+++ b/src/engine/api/geary-logging.vala
@@ -61,7 +61,8 @@ public class Record {
     /** Returns the GLib domain of the log message. */
     public string domain { get; private set; }
 
-    internal Record? next = null;
+    /** Returns the next log record in the buffer, if any. */
+    public Record? next { get; internal set; default = null; }
 
     private LogLevelFlags flags;
     private int64 timestamp;
@@ -81,11 +82,6 @@ public class Record {
         this.message = message;
     }
 
-    /** Returns the next log record in the buffer, if any. */
-    public Record? get_next() {
-        return this.next;
-    }
-
     /** Returns a formatted string representation of this record. */
     public string format() {
         GLib.DateTime time = new GLib.DateTime.from_unix_utc(


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]