GTK3: avoid crash in style editor

svn: r20282
This commit is contained in:
Benny Malengier 2012-08-29 12:53:36 +00:00
parent 185883c0ab
commit 6536b74a59
2 changed files with 48 additions and 46 deletions

View File

@ -50,6 +50,7 @@
<object class="GtkBox" id="dialog-vbox2"> <object class="GtkBox" id="dialog-vbox2">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="orientation">vertical</property>
<child internal-child="action_area"> <child internal-child="action_area">
<object class="GtkButtonBox" id="dialog-action_area2"> <object class="GtkButtonBox" id="dialog-action_area2">
<property name="visible">True</property> <property name="visible">True</property>
@ -290,7 +291,7 @@
<packing> <packing>
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -311,7 +312,7 @@
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="bottom_attach">2</property> <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -333,7 +334,7 @@
<property name="top_attach">2</property> <property name="top_attach">2</property>
<property name="bottom_attach">3</property> <property name="bottom_attach">3</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -351,7 +352,7 @@
<property name="top_attach">3</property> <property name="top_attach">3</property>
<property name="bottom_attach">4</property> <property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -368,7 +369,7 @@
<property name="top_attach">4</property> <property name="top_attach">4</property>
<property name="bottom_attach">5</property> <property name="bottom_attach">5</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -385,7 +386,7 @@
<property name="top_attach">4</property> <property name="top_attach">4</property>
<property name="bottom_attach">5</property> <property name="bottom_attach">5</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -403,7 +404,7 @@
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="bottom_attach">6</property> <property name="bottom_attach">6</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -443,7 +444,7 @@
<property name="top_attach">8</property> <property name="top_attach">8</property>
<property name="bottom_attach">9</property> <property name="bottom_attach">9</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -464,7 +465,7 @@
<property name="top_attach">9</property> <property name="top_attach">9</property>
<property name="bottom_attach">10</property> <property name="bottom_attach">10</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -485,7 +486,7 @@
<property name="top_attach">10</property> <property name="top_attach">10</property>
<property name="bottom_attach">11</property> <property name="bottom_attach">11</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -501,7 +502,7 @@
<property name="top_attach">6</property> <property name="top_attach">6</property>
<property name="bottom_attach">7</property> <property name="bottom_attach">7</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -518,7 +519,7 @@
<property name="top_attach">6</property> <property name="top_attach">6</property>
<property name="bottom_attach">7</property> <property name="bottom_attach">7</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
</object> </object>
@ -598,7 +599,7 @@
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="bottom_attach">2</property> <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -620,7 +621,7 @@
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="bottom_attach">2</property> <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -642,7 +643,7 @@
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="bottom_attach">2</property> <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -664,7 +665,7 @@
<property name="top_attach">1</property> <property name="top_attach">1</property>
<property name="bottom_attach">2</property> <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -699,7 +700,7 @@
<property name="top_attach">2</property> <property name="top_attach">2</property>
<property name="bottom_attach">3</property> <property name="bottom_attach">3</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -718,7 +719,7 @@
<property name="top_attach">7</property> <property name="top_attach">7</property>
<property name="bottom_attach">8</property> <property name="bottom_attach">8</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -735,7 +736,7 @@
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="bottom_attach">6</property> <property name="bottom_attach">6</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -752,7 +753,7 @@
<property name="top_attach">6</property> <property name="top_attach">6</property>
<property name="bottom_attach">7</property> <property name="bottom_attach">7</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -769,7 +770,7 @@
<property name="top_attach">7</property> <property name="top_attach">7</property>
<property name="bottom_attach">8</property> <property name="bottom_attach">8</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -788,7 +789,7 @@
<property name="top_attach">6</property> <property name="top_attach">6</property>
<property name="bottom_attach">7</property> <property name="bottom_attach">7</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -807,7 +808,7 @@
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="bottom_attach">6</property> <property name="bottom_attach">6</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -826,7 +827,7 @@
<property name="top_attach">8</property> <property name="top_attach">8</property>
<property name="bottom_attach">9</property> <property name="bottom_attach">9</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -845,7 +846,7 @@
<property name="top_attach">9</property> <property name="top_attach">9</property>
<property name="bottom_attach">10</property> <property name="bottom_attach">10</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -864,7 +865,7 @@
<property name="top_attach">10</property> <property name="top_attach">10</property>
<property name="bottom_attach">11</property> <property name="bottom_attach">11</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -881,7 +882,7 @@
<property name="top_attach">9</property> <property name="top_attach">9</property>
<property name="bottom_attach">10</property> <property name="bottom_attach">10</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -898,7 +899,7 @@
<property name="top_attach">10</property> <property name="top_attach">10</property>
<property name="bottom_attach">11</property> <property name="bottom_attach">11</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -917,7 +918,7 @@
<property name="top_attach">11</property> <property name="top_attach">11</property>
<property name="bottom_attach">12</property> <property name="bottom_attach">12</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -934,7 +935,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">6</property> <property name="top_attach">6</property>
<property name="bottom_attach">7</property> <property name="bottom_attach">7</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -951,7 +952,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">7</property> <property name="top_attach">7</property>
<property name="bottom_attach">8</property> <property name="bottom_attach">8</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -968,7 +969,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">5</property> <property name="top_attach">5</property>
<property name="bottom_attach">6</property> <property name="bottom_attach">6</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -985,7 +986,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">9</property> <property name="top_attach">9</property>
<property name="bottom_attach">10</property> <property name="bottom_attach">10</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1002,7 +1003,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">10</property> <property name="top_attach">10</property>
<property name="bottom_attach">11</property> <property name="bottom_attach">11</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1023,7 +1024,7 @@
<property name="top_attach">13</property> <property name="top_attach">13</property>
<property name="bottom_attach">14</property> <property name="bottom_attach">14</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1044,7 +1045,7 @@
<property name="top_attach">13</property> <property name="top_attach">13</property>
<property name="bottom_attach">14</property> <property name="bottom_attach">14</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1065,7 +1066,7 @@
<property name="top_attach">13</property> <property name="top_attach">13</property>
<property name="bottom_attach">14</property> <property name="bottom_attach">14</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1084,7 +1085,7 @@
<property name="top_attach">12</property> <property name="top_attach">12</property>
<property name="bottom_attach">13</property> <property name="bottom_attach">13</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1101,7 +1102,7 @@
<property name="right_attach">4</property> <property name="right_attach">4</property>
<property name="top_attach">12</property> <property name="top_attach">12</property>
<property name="bottom_attach">13</property> <property name="bottom_attach">13</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1118,7 +1119,7 @@
<property name="top_attach">12</property> <property name="top_attach">12</property>
<property name="bottom_attach">13</property> <property name="bottom_attach">13</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1139,7 +1140,7 @@
<property name="top_attach">13</property> <property name="top_attach">13</property>
<property name="bottom_attach">14</property> <property name="bottom_attach">14</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1155,7 +1156,7 @@
<property name="top_attach">3</property> <property name="top_attach">3</property>
<property name="bottom_attach">4</property> <property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1171,7 +1172,7 @@
<property name="top_attach">4</property> <property name="top_attach">4</property>
<property name="bottom_attach">5</property> <property name="bottom_attach">5</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
<child> <child>
@ -1188,7 +1189,7 @@
<property name="top_attach">3</property> <property name="top_attach">3</property>
<property name="bottom_attach">4</property> <property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property> <property name="x_options">GTK_FILL</property>
<property name="y_options"/> <property name="y_options"></property>
</packing> </packing>
</child> </child>
</object> </object>
@ -1244,6 +1245,7 @@
<object class="GtkBox" id="dialog-vbox1"> <object class="GtkBox" id="dialog-vbox1">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="orientation">vertical</property>
<child internal-child="action_area"> <child internal-child="action_area">
<object class="GtkButtonBox" id="dialog-action_area1"> <object class="GtkButtonBox" id="dialog-action_area1">
<property name="visible">True</property> <property name="visible">True</property>

View File

@ -100,7 +100,7 @@ class StyleListDisplay(object):
[(_('Style'), -1, 10)], ) [(_('Style'), -1, 10)], )
self.redraw() self.redraw()
if parent_window: if parent_window:
self.set_transient_for(parent_window) self.window.set_transient_for(parent_window)
self.window.run() self.window.run()
self.window.destroy() self.window.destroy()
@ -229,7 +229,7 @@ class StyleEditor(object):
self.plist.select_row(0) self.plist.select_row(0)
if self.parent: if self.parent:
self.set_transient_for(parent.window) self.window.set_transient_for(parent.window)
self.window.run() self.window.run()
self.window.destroy() self.window.destroy()