Skip to content
This repository has been archived by the owner on Dec 18, 2019. It is now read-only.

Commit

Permalink
Frontend: Main window: Scrap the toolbars
Browse files Browse the repository at this point in the history
Signed-off-by: Jerome Flesch <jflesch@gmail.com>
  • Loading branch information
jflesch committed Jan 12, 2015
1 parent ae3bb68 commit 09bd226
Show file tree
Hide file tree
Showing 2 changed files with 537 additions and 861 deletions.
30 changes: 17 additions & 13 deletions src/paperwork/frontend/mainwindow/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2901,11 +2901,12 @@ def __init__(self, config):
),
}

for action in self.actions:
for button in self.actions[action][0]:
if button is None:
logger.error("MISSING BUTTON: %s" % (action))
self.actions[action][1].connect(self.actions[action][0])
# TODO
#for action in self.actions:
# for button in self.actions[action][0]:
# if button is None:
# logger.error("MISSING BUTTON: %s" % (action))
# self.actions[action][1].connect(self.actions[action][0])

for (buttons, action) in self.actions.values():
for button in buttons:
Expand All @@ -2925,12 +2926,13 @@ def __init__(self, config):
('<Primary>f', 'grab-focus',
self.search_field),
]
accel_group = Gtk.AccelGroup()
for (shortcut, signame, widget) in accelerators:
(key, mod) = Gtk.accelerator_parse(shortcut)
widget.add_accelerator(signame, accel_group, key, mod,
Gtk.AccelFlags.VISIBLE)
self.window.add_accel_group(accel_group)
# TODO
#accel_group = Gtk.AccelGroup()
#for (shortcut, signame, widget) in accelerators:
# (key, mod) = Gtk.accelerator_parse(shortcut)
# widget.add_accelerator(signame, accel_group, key, mod,
# Gtk.AccelFlags.VISIBLE)
#self.window.add_accel_group(accel_group)

self.need_doc_widgets = set(
self.actions['print'][0]
Expand Down Expand Up @@ -2963,7 +2965,8 @@ def __init__(self, config):
+ self.actions['edit_page'][0]
)

set_widget_state(self.need_page_widgets, False)
# TODO
# set_widget_state(self.need_page_widgets, False)

for (popup_menu_name, popup_menu) in self.popup_menus.iteritems():
assert(not popup_menu[0] is None)
Expand Down Expand Up @@ -3100,7 +3103,8 @@ def set_raw_zoom_level(self, level):
logger.warning("Unknown zoom level: %f" % level)
return

self.lists['zoom_levels']['gui'].set_active(new_idx)
# TODO
# self.lists['zoom_levels']['gui'].set_active(new_idx)

def on_index_loading_start_cb(self, src):
self.set_progression(src, 0.0, None)
Expand Down
Loading

0 comments on commit 09bd226

Please sign in to comment.