Places: no height adjustment when auto
The height adjustment box is insensitive when scrolling is disabled
This commit is contained in:
parent
d3a96e305e
commit
79ff1b93c9
@ -870,7 +870,7 @@
|
|||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<widget class="GtkSpinButton" id="placesHeightSpinBox">
|
<widget class="GtkSpinButton" id="placesHeightSpinButton">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can_focus">True</property>
|
<property name="can_focus">True</property>
|
||||||
<property name="max_length">5</property>
|
<property name="max_length">5</property>
|
||||||
|
@ -123,7 +123,10 @@ class mintMenuConfig( object ):
|
|||||||
self.trashtoggle = wTree.get_widget( "trashcheckbutton" )
|
self.trashtoggle = wTree.get_widget( "trashcheckbutton" )
|
||||||
self.customplacestree = wTree.get_widget( "customplacestree" )
|
self.customplacestree = wTree.get_widget( "customplacestree" )
|
||||||
self.allowScrollbarToggle = wTree.get_widget( "allowscrollbarcheckbutton" )
|
self.allowScrollbarToggle = wTree.get_widget( "allowscrollbarcheckbutton" )
|
||||||
self.placesHeightBox = wTree.get_widget( "placesHeightSpinBox" )
|
self.placesHeightButton = wTree.get_widget( "placesHeightSpinButton" )
|
||||||
|
if (self.allowScrollbarToggle.get_active() == False):
|
||||||
|
self.placesHeightButton.set_sensitive(False)
|
||||||
|
self.allowScrollbarToggle.connect("toggled", self.toggleHeightEnabled )
|
||||||
wTree.get_widget( "closeButton" ).connect("clicked", gtk.main_quit )
|
wTree.get_widget( "closeButton" ).connect("clicked", gtk.main_quit )
|
||||||
|
|
||||||
|
|
||||||
@ -164,7 +167,7 @@ class mintMenuConfig( object ):
|
|||||||
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_network", self.networktoggle, "toggled", self.networktoggle.set_active, self.networktoggle.get_active )
|
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_network", self.networktoggle, "toggled", self.networktoggle.set_active, self.networktoggle.get_active )
|
||||||
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_desktop", self.desktoptoggle, "toggled", self.desktoptoggle.set_active, self.desktoptoggle.get_active )
|
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_desktop", self.desktoptoggle, "toggled", self.desktoptoggle.set_active, self.desktoptoggle.get_active )
|
||||||
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_trash", self.trashtoggle, "toggled", self.trashtoggle.set_active, self.trashtoggle.get_active )
|
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "show_trash", self.trashtoggle, "toggled", self.trashtoggle.set_active, self.trashtoggle.get_active )
|
||||||
self.bindGconfValueToWidget( self.gconfPlaces, "int", "height", self.placesHeightBox, "value-changed", self.placesHeightBox.set_value, self.placesHeightBox.get_value_as_int )
|
self.bindGconfValueToWidget( self.gconfPlaces, "int", "height", self.placesHeightButton, "value-changed", self.placesHeightButton.set_value, self.placesHeightButton.get_value_as_int )
|
||||||
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "allowScrollbar", self.allowScrollbarToggle, "toggled", self.allowScrollbarToggle.set_active, self.allowScrollbarToggle.get_active )
|
self.bindGconfValueToWidget( self.gconfPlaces, "bool", "allowScrollbar", self.allowScrollbarToggle, "toggled", self.allowScrollbarToggle.set_active, self.allowScrollbarToggle.get_active )
|
||||||
|
|
||||||
self.customplacenames = self.gconfPlaces.get( "list-string", "custom_names", [ ] )
|
self.customplacenames = self.gconfPlaces.get( "list-string", "custom_names", [ ] )
|
||||||
@ -373,6 +376,12 @@ class mintMenuConfig( object ):
|
|||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
def toggleHeightEnabled(self, toggle):
|
||||||
|
if (toggle.get_active() == True):
|
||||||
|
self.placesHeightButton.set_sensitive(True)
|
||||||
|
else:
|
||||||
|
self.placesHeightButton.set_sensitive(False)
|
||||||
|
|
||||||
def updatePlacesGconf(self):
|
def updatePlacesGconf(self):
|
||||||
treeiter = self.customplacestreemodel.get_iter_first()
|
treeiter = self.customplacestreemodel.get_iter_first()
|
||||||
customplacenames = [ ]
|
customplacenames = [ ]
|
||||||
|
Loading…
Reference in New Issue
Block a user