improve stats menu on hud
This commit is contained in:
parent
d36d8f4249
commit
b0037e545a
|
@ -152,38 +152,32 @@ class Hud:
|
||||||
aggitem.set_submenu(self.aggMenu)
|
aggitem.set_submenu(self.aggMenu)
|
||||||
# set agg_bb_mult to 1 to stop aggregation
|
# set agg_bb_mult to 1 to stop aggregation
|
||||||
item = gtk.CheckMenuItem('For This Blind Level Only')
|
item = gtk.CheckMenuItem('For This Blind Level Only')
|
||||||
item.ms = 1
|
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_aggregation)
|
item.connect("activate", self.set_aggregation, 1)
|
||||||
setattr(self, 'showStatsMenuItem1', item)
|
setattr(self, 'aggBBmultItem1', item)
|
||||||
#
|
#
|
||||||
item = gtk.MenuItem('For Multiple Blind Levels:')
|
item = gtk.MenuItem('For Multiple Blind Levels:')
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
setattr(self, 'showStatsMenuItem2', item)
|
|
||||||
#
|
#
|
||||||
item = gtk.CheckMenuItem(' 0.5 to 2.0 x Current Blinds')
|
item = gtk.CheckMenuItem(' 0.5 to 2.0 x Current Blinds')
|
||||||
item.ms = 2
|
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_aggregation)
|
item.connect("activate", self.set_aggregation, 2)
|
||||||
setattr(self, 'showStatsMenuItem3', item)
|
setattr(self, 'aggBBmultItem2', item)
|
||||||
#
|
#
|
||||||
item = gtk.CheckMenuItem(' 0.33 to 3.0 x Current Blinds')
|
item = gtk.CheckMenuItem(' 0.33 to 3.0 x Current Blinds')
|
||||||
item.ms = 3
|
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_aggregation)
|
item.connect("activate", self.set_aggregation, 3)
|
||||||
setattr(self, 'showStatsMenuItem4', item)
|
setattr(self, 'aggBBmultItem3', item)
|
||||||
#
|
#
|
||||||
item = gtk.CheckMenuItem(' 0.1 to 10 x Current Blinds')
|
item = gtk.CheckMenuItem(' 0.1 to 10 x Current Blinds')
|
||||||
item.ms = 10
|
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_aggregation)
|
item.connect("activate", self.set_aggregation, 10)
|
||||||
setattr(self, 'showStatsMenuItem5', item)
|
setattr(self, 'aggBBmultItem10', item)
|
||||||
#
|
#
|
||||||
item = gtk.CheckMenuItem(' All Levels')
|
item = gtk.CheckMenuItem(' All Levels')
|
||||||
item.ms = 10000
|
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_aggregation)
|
item.connect("activate", self.set_aggregation, 10000)
|
||||||
setattr(self, 'showStatsMenuItem6', item)
|
setattr(self, 'aggBBmultItemAll', item)
|
||||||
#
|
#
|
||||||
item = gtk.MenuItem('For Hero:')
|
item = gtk.MenuItem('For Hero:')
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
|
@ -203,12 +197,24 @@ class Hud:
|
||||||
self.aggMenu.append(item)
|
self.aggMenu.append(item)
|
||||||
item.connect("activate", self.set_hud_style, 'HT')
|
item.connect("activate", self.set_hud_style, 'HT')
|
||||||
setattr(self, 'HTStyleOption', item)
|
setattr(self, 'HTStyleOption', item)
|
||||||
|
|
||||||
|
# set active on current options:
|
||||||
|
if self.hud_params['agg_bb_mult'] == 1:
|
||||||
|
getattr(self, 'aggBBmultItem1').set_active(True)
|
||||||
|
elif self.hud_params['agg_bb_mult'] == 2:
|
||||||
|
getattr(self, 'aggBBmultItem2').set_active(True)
|
||||||
|
elif self.hud_params['agg_bb_mult'] == 3:
|
||||||
|
getattr(self, 'aggBBmultItem3').set_active(True)
|
||||||
|
elif self.hud_params['agg_bb_mult'] == 10:
|
||||||
|
getattr(self, 'aggBBmultItem10').set_active(True)
|
||||||
|
elif self.hud_params['agg_bb_mult'] > 9000:
|
||||||
|
getattr(self, 'aggBBmultItemAll').set_active(True)
|
||||||
if self.hud_params['h_hud_style'] == 'A':
|
if self.hud_params['h_hud_style'] == 'A':
|
||||||
item.set_active(True)
|
getattr(self, 'HAStyleOption').set_active(True)
|
||||||
if self.hud_params['h_hud_style'] == 'S':
|
elif self.hud_params['h_hud_style'] == 'S':
|
||||||
item.set_active(True)
|
getattr(self, 'HSStyleOption').set_active(True)
|
||||||
if self.hud_params['h_hud_style'] == 'T':
|
elif self.hud_params['h_hud_style'] == 'T':
|
||||||
item.set_active(True)
|
getattr(self, 'HTStyleOption').set_active(True)
|
||||||
|
|
||||||
eventbox.connect_object("button-press-event", self.on_button_press, menu)
|
eventbox.connect_object("button-press-event", self.on_button_press, menu)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user