mirror of
https://github.com/gryf/pygtktalog.git
synced 2025-12-17 19:40:21 +01:00
* Upgraded pygtkmvc to version 1.0.1.
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
# Author: Roberto Cavada <cavada@irst.itc.it>
|
||||
# Modified by: Guillaume Libersat <glibersat AT linux62.org>
|
||||
#
|
||||
# Copyright (c) 2005 by Roberto Cavada
|
||||
# Copyright (c) 2007 by Guillaume Libersat
|
||||
#
|
||||
# pygtkmvc is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
@@ -37,6 +39,9 @@ class View (object):
|
||||
self.manualWidgets = {}
|
||||
self.xmlWidgets = []
|
||||
|
||||
# Sets a callback for custom widgets
|
||||
gtk.glade.set_custom_handler(self._custom_widget_create)
|
||||
|
||||
if (( type(glade_top_widget_name) == types.StringType)
|
||||
or (glade_top_widget_name is None) ):
|
||||
wids = (glade_top_widget_name,)
|
||||
@@ -155,4 +160,11 @@ class View (object):
|
||||
pass
|
||||
return
|
||||
|
||||
# Finds the right callback for custom widget creation and call it
|
||||
def _custom_widget_create(self, glade, function_name, widget_name,
|
||||
str1, str2, int1, int2):
|
||||
handler = getattr(self, function_name)
|
||||
return handler(str1, str2, int1, int2)
|
||||
|
||||
|
||||
pass # end of class View
|
||||
|
||||
Reference in New Issue
Block a user