src/Builder4/MainWindow.bjs
authorAlan Knowles <alan@roojs.com>
Tue, 2 Jun 2015 12:21:48 +0000 (20:21 +0800)
committerAlan Knowles <alan@roojs.com>
Tue, 2 Jun 2015 12:21:48 +0000 (20:21 +0800)
src/Builder4/MainWindow.vala

src/Builder4/MainWindow.bjs
src/Builder4/MainWindow.vala

index 120ab1e..ebba7d5 100644 (file)
         },
         {
          "listeners" : {
-          "changed" : "() => {\n\tif (this.el.text == \"\") {\n\t\treturn;\n\t}\n\tGee.ArrayList<int> res = new Gee.ArrayList<int>();;\n\tswitch(_this.windowstate.state) {\n\t\tcase WindowState.State.CODEONLY:\n\t\tcase WindowState.State.CODE:\n\t\t\t// search the code being edited..\n\t\t\tres = _this.windowstate.code_editor.search(this.el.text);\n\t\t\t\n\t\t\tbreak;\n\t\tcase WindowState.State.PREVIEW:\n\t\t\tif (_this.windowstate.file.xtype == \"Gtk\") {\n\t\t\t\tvar res = _this.windowstate.window_gladeview.search(this.el.text);\n\t\t\t}\n\t\t\n\t\t\tbreak;\n\t}\n\tif (res.size > 0) {\n\t\t_this.search_results.el.label = \"%d Matches\".printf(res.size);\n\t} else {\n\t\t_this.search_results.el.label = \"No Matches\";\n\t}\n\t\t\n\t\n\t\n}\n"
+          "changed" : "() => {\n\tif (this.el.text == \"\") {\n\t\treturn;\n\t}\n\tGee.ArrayList<int> res = new Gee.ArrayList<int>();\n\tswitch(_this.windowstate.state) {\n\t\tcase WindowState.State.CODEONLY:\n\t\tcase WindowState.State.CODE:\n\t\t\t// search the code being edited..\n\t\t\tres = _this.windowstate.code_editor.search(this.el.text);\n\t\t\t\n\t\t\tbreak;\n\t\tcase WindowState.State.PREVIEW:\n\t\t\tif (_this.windowstate.file.xtype == \"Gtk\") {\n\t\t\t\tvar res = _this.windowstate.window_gladeview.search(this.el.text);\n\t\t\t}\n\t\t\n\t\t\tbreak;\n\t}\n\tif (res.size > 0) {\n\t\t_this.search_results.el.label = \"%d Matches\".printf(res.size);\n\t} else {\n\t\t_this.search_results.el.label = \"No Matches\";\n\t}\n\t\t\n\t\n\t\n}\n"
          },
          "id" : "search_entry",
          "* init" : "var description =   Pango.FontDescription.from_string(\"monospace\");\n\tdescription.set_size(8000);\n\t this.el.override_font(description);\n\n",
index 6efb8fd..9bae8b3 100644 (file)
@@ -2330,7 +2330,7 @@ public class Xcls_MainWindow : Object
                if (this.el.text == "") {
                        return;
                }
-               Gee.ArrayList<int> res = new Gee.ArrayList<int>();;
+               Gee.ArrayList<int> res = new Gee.ArrayList<int>();
                switch(_this.windowstate.state) {
                        case WindowState.State.CODEONLY:
                        case WindowState.State.CODE: