From 8fc0f9451e63c92ec99eadb8cd13dd69ded69156 Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Mon, 04 Jul 2011 15:07:26 -0400
Subject: [PATCH] - Fix GCC errors and warnings (#1487988)

---
 bin/jsshrink.sh      |    5 -----
 program/js/common.js |   26 +++++++++++---------------
 bin/jsunshrink.sh    |   10 ----------
 program/js/app.js    |    8 ++++----
 4 files changed, 15 insertions(+), 34 deletions(-)

diff --git a/bin/jsshrink.sh b/bin/jsshrink.sh
index b85f517..be5aad1 100755
--- a/bin/jsshrink.sh
+++ b/bin/jsshrink.sh
@@ -41,8 +41,3 @@
 	echo "Shrinking $JS_DIR/${fn}.js"
 	do_shrink "$JS_DIR/${fn}.js.src" "$JS_DIR/${fn}.js"
 done
-
-for fn in tiny_mce/tiny_mce; do
-	echo "Shrinking $JS_DIR/${fn}.js"
-	do_shrink "$JS_DIR/${fn}_src.js" "$JS_DIR/${fn}.js"
-done
diff --git a/bin/jsunshrink.sh b/bin/jsunshrink.sh
index 90c3ea5..9d77550 100755
--- a/bin/jsunshrink.sh
+++ b/bin/jsunshrink.sh
@@ -12,13 +12,3 @@
 		echo "Reverted $JS_DIR/${fn}.js"
 	fi
 done
-
-for fn in tiny_mce/tiny_mce; do
-	if [ -d "$JS_DIR/.svn" ] && which svn >/dev/null 2>&1; then
-		rm -f "$JS_DIR/${fn}.js"
-		svn revert "$JS_DIR/${fn}.js"
-	else
-		cp "$JS_DIR/${fn}_src.js" "$JS_DIR/${fn}.js"
-		echo "Reverted $JS_DIR/${fn}.js"
-	fi
-done
diff --git a/program/js/app.js b/program/js/app.js
index 5a9ed21..a9c345b 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -4489,7 +4489,7 @@
   };
 
   // Add folder row to the table and initialize it
-  this.add_folder_row = function (name, display_name, protected, subscribed, skip_init, class_name)
+  this.add_folder_row = function (name, display_name, is_protected, subscribed, skip_init, class_name)
   {
     if (!this.gui_objects.subscriptionlist)
       return false;
@@ -4517,7 +4517,7 @@
 
     // update subscription checkbox
     $('input[name="_subscribed[]"]', row).val(name)
-      .prop({checked: subscribed ? true : false, disabled: protected ? true : false});
+      .prop({checked: subscribed ? true : false, disabled: is_protected ? true : false});
 
     // add to folder/row-ID map
     this.env.subscriptionrows[id] = [name, display_name, 0];
@@ -4568,7 +4568,7 @@
   };
 
   // replace an existing table row with a new folder line (with subfolders)
-  this.replace_folder_row = function(oldfolder, newfolder, display_name, protected, class_name)
+  this.replace_folder_row = function(oldfolder, newfolder, display_name, is_protected, class_name)
   {
     if (!this.gui_objects.subscriptionlist)
       return false;
@@ -4584,7 +4584,7 @@
 
     // replace an existing table row
     this._remove_folder_row(id);
-    row = $(this.add_folder_row(newfolder, display_name, protected, subscribed, true, class_name));
+    row = $(this.add_folder_row(newfolder, display_name, is_protected, subscribed, true, class_name));
 
     // detect tree depth change
     if (len = list.length) {
diff --git a/program/js/common.js b/program/js/common.js
index 16f2ebf..cacf0ff 100644
--- a/program/js/common.js
+++ b/program/js/common.js
@@ -383,21 +383,17 @@
       parent = arg.parent,
       obj = document.createElement('DIV');
 
-    with (obj) {
-      id = this.name;
-      with (style) {
-	    position = 'absolute';
-        visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden';
-        left = l+'px';
-        top = t+'px';
-        if (w)
-	      width = w.toString().match(/\%$/) ? w : w+'px';
-        if (h)
-	      height = h.toString().match(/\%$/) ? h : h+'px';
-        if (z)
-          zIndex = z;
-	  }
-    }
+    obj.id = this.name;
+    obj.style.position = 'absolute';
+    obj.style.visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden';
+    obj.style.left = l+'px';
+    obj.style.top = t+'px';
+    if (w)
+	  obj.style.width = w.toString().match(/\%$/) ? w : w+'px';
+    if (h)
+	  obj.style.height = h.toString().match(/\%$/) ? h : h+'px';
+    if (z)
+      obj.style.zIndex = z;
 
     if (parent)
       parent.appendChild(obj);

--
Gitblit v1.9.1