← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 13809: Fixd issue with extending the left side menu width function

 

------------------------------------------------------------
revno: 13809
committer: Lars Helge Øverland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2014-01-22 14:06:59 +0200
message:
  Fixd issue with extending the left side menu width function
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.vm


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js	2013-10-22 18:10:32 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js	2014-01-22 12:06:59 +0000
@@ -147,7 +147,7 @@
 	$( '#mainPage' ).css( 'margin-left', '' );
 };
 
-dhis2.leftBar.extend = function()
+dhis2.leftBar.extendAnimated = function()
 {
 	dhis2.leftBar.setMenuExtended();
 	dhis2.leftBar.setLinks( false, false );
@@ -156,6 +156,15 @@
     $( '#hideMainMenuLink' ).attr( 'href', 'javascript:dhis2.leftBar.retract()' );
 };
 
+dhis2.leftBar.extend = function()
+{
+	dhis2.leftBar.setMenuExtended();
+	dhis2.leftBar.setLinks( false, false );
+    $( '#leftBar, #orgUnitTree' ).show().css( "width", "+=150px" );
+    $( '#mainPage' ).css( "margin-left", "+=150px" );
+    $( '#hideMainMenuLink' ).attr( 'href', 'javascript:dhis2.leftBar.retract()' );
+};
+
 dhis2.leftBar.retract = function()
 {
 	dhis2.leftBar.setMenuVisible();

=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.vm'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.vm	2013-12-30 19:18:06 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.vm	2014-01-22 12:06:59 +0000
@@ -140,7 +140,7 @@
           <img src="../images/home_small.png" width="16" height="16" /></a>
         <a href="javascript:dhis2.leftBar.hideAnimated()" title="$i18n.getString( 'hide_menu' )" id="hideMainMenuLink">
           <img src="../images/hide_menu.png" width="16" height="16" /></a>
-        <a href="javascript:dhis2.leftBar.extend()" title="$i18n.getString( 'extend_menu' )" id="extendMainMenuLink">
+        <a href="javascript:dhis2.leftBar.extendAnimated()" title="$i18n.getString( 'extend_menu' )" id="extendMainMenuLink">
           <img src="../images/extend_menu.png" width="16" height="16" /></a>
       </div>