Public bug reported:

When you define submenu in act_window the path to load icon is wrong.

here a patch proposed


=== modified file 'bin/widget/view/form.py'
--- bin/widget/view/form.py     2011-01-13 06:54:27 +0000
+++ bin/widget/view/form.py     2011-12-13 05:03:51 +0000
@@ -112,7 +112,7 @@
             for sub in eval(submenu):
                 sbutton = gtk.Button()
                 icon = gtk.Image()
-                file_path = os.path.realpath("icons")
+                file_path = os.path.realpath("bin/icons")
                 iname = sub.get('icon', 'terp-marketing').split('-')[1]
                 pixbuf = gtk.gdk.pixbuf_new_from_file(file_path + '/' + iname 
+ '.png')
                 icon_set = gtk.IconSet(pixbuf)

** Affects: openobject-client
     Importance: Undecided
         Status: New


** Tags: client submenu

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to OpenERP Project Group.
https://bugs.launchpad.net/bugs/903553

Title:
  icon path wrong with submenu

Status in OpenERP GTK Client:
  New

Bug description:
  When you define submenu in act_window the path to load icon is wrong.

  here a patch proposed

  
  === modified file 'bin/widget/view/form.py'
  --- bin/widget/view/form.py   2011-01-13 06:54:27 +0000
  +++ bin/widget/view/form.py   2011-12-13 05:03:51 +0000
  @@ -112,7 +112,7 @@
               for sub in eval(submenu):
                   sbutton = gtk.Button()
                   icon = gtk.Image()
  -                file_path = os.path.realpath("icons")
  +                file_path = os.path.realpath("bin/icons")
                   iname = sub.get('icon', 'terp-marketing').split('-')[1]
                   pixbuf = gtk.gdk.pixbuf_new_from_file(file_path + '/' + 
iname + '.png')
                   icon_set = gtk.IconSet(pixbuf)

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-client/+bug/903553/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~c2c-oerpscenario
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~c2c-oerpscenario
More help   : https://help.launchpad.net/ListHelp

Reply via email to