]> git.wh0rd.org - tt-rss.git/commitdiff
triple-pane: do not try to rework UI using javascript while in CDM
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 27 Dec 2010 09:40:46 +0000 (12:40 +0300)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 27 Dec 2010 09:40:46 +0000 (12:40 +0300)
themes/triple-pane/theme.js

index 0880553066e117fc88c616ce57bfcdbd5484b355..2fddab03b551831d1e9840132a58c8b6c6cc38da 100644 (file)
@@ -1,14 +1,18 @@
 function themeBeforeLayout() {
-       $("headlines-wrap-inner").setAttribute("design", 'sidebar');
-       $("content-insert").setAttribute("region", "trailing");
-       $("content-insert").setStyle({
-               width: '50%',
-               height: 'auto'});
+       if ($("content-insert")) {
+               $("headlines-wrap-inner").setAttribute("design", 'sidebar');
+               $("content-insert").setAttribute("region", "trailing");
+               $("content-insert").setStyle({
+                       width: '50%',
+                       height: 'auto'});
+       }
 }
 
 function themeAfterLayout() {
-       $("headlines-toolbar").setStyle({
-               'border-right-width': '1px',
-               'border-color': '#88b0f0',
-               });
+       if ($("content-insert")) {
+               $("headlines-toolbar").setStyle({
+                       'border-right-width': '1px',
+                       'border-color': '#88b0f0',
+                       });
+       }
 }