[anjuta] class-gen: Use the new project node chooser
- From: Sebastien Granjoux <sgranjoux src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [anjuta] class-gen: Use the new project node chooser
- Date: Sat, 7 Jan 2012 11:29:02 +0000 (UTC)
commit bb873f2aa144b0ee551d3a4e2bfaf67ed5cb4a43
Author: SÃbastien Granjoux <seb sfo free fr>
Date: Fri Jan 6 22:27:17 2012 +0100
class-gen: Use the new project node chooser
plugins/class-gen/anjuta-class-gen-plugin.ui | 502 ++++++++++++++++++++------
plugins/class-gen/anjuta-class-gen.plugin.in | 1 +
plugins/class-gen/plugin.c | 98 +++---
plugins/class-gen/window.c | 203 +++++++----
plugins/class-gen/window.h | 6 +
5 files changed, 584 insertions(+), 226 deletions(-)
---
diff --git a/plugins/class-gen/anjuta-class-gen-plugin.ui b/plugins/class-gen/anjuta-class-gen-plugin.ui
index 5512445..82bab46 100644
--- a/plugins/class-gen/anjuta-class-gen-plugin.ui
+++ b/plugins/class-gen/anjuta-class-gen-plugin.ui
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
- <requires lib="gtk+" version="2.16"/>
- <!-- interface-naming-policy toplevel-contextual -->
+ <!-- interface-requires gtk+ 3.0 -->
+ <!-- interface-requires anjuta 0.0 -->
<object class="GtkListStore" id="model1">
<columns>
<!-- column-name gchararray -->
@@ -54,39 +54,125 @@
</data>
</object>
<object class="GtkDialog" id="classgen_main">
+ <property name="can_focus">False</property>
<property name="title" translatable="yes">Class Generator</property>
<property name="default_height">582</property>
<property name="type_hint">dialog</property>
<child internal-child="vbox">
- <object class="GtkVBox" id="dialog-vbox2">
+ <object class="GtkBox" id="dialog-vbox2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK</property>
+ <property name="orientation">vertical</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="cancel_button">
+ <property name="label">gtk-cancel</property>
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="create_button">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
+ <child>
+ <object class="GtkHBox" id="hbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkImage" id="image1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-save</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label33">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Create</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
<child>
<object class="GtkVBox" id="vbox1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">4</property>
<child>
<object class="GtkNotebook" id="top_notebook">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
<object class="GtkVBox" id="vbox8">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">6</property>
<child>
<object class="GtkFrame" id="frame7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkTable" id="table7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="n_rows">4</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
@@ -94,6 +180,7 @@
<child>
<object class="GtkLabel" id="label38">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Class Name:</property>
<property name="use_underline">True</property>
@@ -119,6 +206,7 @@
<child>
<object class="GtkLabel" id="label39">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Base Class:</property>
<property name="mnemonic_widget">cc_base</property>
@@ -145,6 +233,7 @@
<child>
<object class="GtkLabel" id="label40">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Base Class Inheritance:</property>
</object>
@@ -158,6 +247,7 @@
<child>
<object class="GtkComboBox" id="cc_inheritance">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="model">model1</property>
<child>
<object class="GtkCellRendererText" id="renderer1"/>
@@ -177,6 +267,7 @@
<child>
<object class="GtkLabel" id="label45">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Class Options:</property>
</object>
@@ -190,6 +281,7 @@
<child>
<object class="GtkLabel" id="label46">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source/Header Headings:</property>
</object>
@@ -203,9 +295,11 @@
<child>
<object class="GtkCheckButton" id="cc_inline">
<property name="label" translatable="yes">Inline the declaration and implementation</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="draw_indicator">True</property>
</object>
<packing>
@@ -219,9 +313,11 @@
<child>
<object class="GtkCheckButton" id="cc_headings">
<property name="label" translatable="yes">Author/Date/Time</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
@@ -246,6 +342,7 @@
<child type="label">
<object class="GtkLabel" id="label47">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">General Class Properties</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -255,52 +352,63 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame8">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment8">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkVBox" id="vbox9">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<child>
<object class="GtkScrolledWindow" id="scrolledwindow4">
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="cc_elements">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection1"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox4">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="cc_elements_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -312,9 +420,11 @@
<child>
<object class="GtkButton" id="cc_elements_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -326,6 +436,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -336,6 +447,7 @@
<child type="label">
<object class="GtkLabel" id="label48">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Elements</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -344,6 +456,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -352,6 +466,7 @@
<child type="tab">
<object class="GtkLabel" id="label2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Generic C++ Class</property>
</object>
<packing>
@@ -361,21 +476,25 @@
<child>
<object class="GtkVBox" id="vbox6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">6</property>
<child>
<object class="GtkFrame" id="frame5">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment5">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkTable" id="table3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="n_rows">4</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
@@ -383,6 +502,7 @@
<child>
<object class="GtkLabel" id="label27">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Class Name:</property>
</object>
@@ -406,6 +526,7 @@
<child>
<object class="GtkLabel" id="label28">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Base Class:</property>
</object>
@@ -432,6 +553,7 @@
<child>
<object class="GtkLabel" id="label29">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">GObject Prefix and Type:</property>
</object>
@@ -445,6 +567,7 @@
<child>
<object class="GtkLabel" id="label35">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source/Header Headings:</property>
</object>
@@ -458,9 +581,11 @@
<child>
<object class="GtkCheckButton" id="go_headings">
<property name="label" translatable="yes">Author/Date-Time</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
@@ -475,6 +600,7 @@
<child>
<object class="GtkHBox" id="hbox4">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
<object class="GtkEntry" id="go_prefix">
<property name="visible">True</property>
@@ -484,19 +610,20 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
- <property name="y_options">GTK_FILL</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="label49">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label">_TYPE_</property>
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
- <property name="y_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -506,8 +633,9 @@
<property name="activates_default">True</property>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">2</property>
- <property name="y_options">GTK_FILL</property>
</packing>
</child>
</object>
@@ -522,6 +650,7 @@
<child>
<object class="GtkLabel" id="label51">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Class Function Prefix:</property>
</object>
@@ -559,6 +688,7 @@
<child type="label">
<object class="GtkLabel" id="label36">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">General Class Properties</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -568,25 +698,30 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkNotebook" id="notebook2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
<object class="GtkVBox" id="vbox10">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -594,30 +729,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="go_members">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection2"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox5">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="go_members_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -629,9 +771,11 @@
<child>
<object class="GtkButton" id="go_members_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -643,6 +787,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -651,6 +796,7 @@
<child type="tab">
<object class="GtkLabel" id="label52">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Member Functions/Variables</property>
</object>
<packing>
@@ -660,6 +806,7 @@
<child>
<object class="GtkVBox" id="vbox12">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -667,30 +814,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="go_properties">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection3"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="go_properties_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -702,9 +856,11 @@
<child>
<object class="GtkButton" id="go_properties_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -716,6 +872,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -727,6 +884,7 @@
<child type="tab">
<object class="GtkLabel" id="label53">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Properties</property>
</object>
<packing>
@@ -737,6 +895,7 @@
<child>
<object class="GtkVBox" id="vbox13">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -744,30 +903,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="go_signals">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection4"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox8">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="go_signals_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -779,9 +945,11 @@
<child>
<object class="GtkButton" id="go_signals_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -793,6 +961,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -804,6 +973,7 @@
<child type="tab">
<object class="GtkLabel" id="label54">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Signals</property>
</object>
<packing>
@@ -818,6 +988,7 @@
<child type="label">
<object class="GtkLabel" id="label37">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Elements</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -826,6 +997,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -837,6 +1010,7 @@
<child type="tab">
<object class="GtkLabel" id="label3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">GObject Class </property>
</object>
<packing>
@@ -847,21 +1021,25 @@
<child>
<object class="GtkVBox" id="vbox_python">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">6</property>
<child>
<object class="GtkFrame" id="frame_python">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkTable" id="table">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="n_rows">4</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
@@ -869,6 +1047,7 @@
<child>
<object class="GtkLabel" id="label9">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Name:</property>
</object>
<packing>
@@ -901,6 +1080,7 @@
<child>
<object class="GtkLabel" id="label10">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Base Class:</property>
</object>
<packing>
@@ -913,6 +1093,7 @@
<child>
<object class="GtkLabel" id="label11">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source/Header Headings:</property>
</object>
@@ -926,9 +1107,11 @@
<child>
<object class="GtkCheckButton" id="py_headings">
<property name="label" translatable="yes">Author/Date/Time</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
@@ -977,6 +1160,7 @@
<child type="label">
<object class="GtkLabel" id="label99">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">General Class Properties</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -986,6 +1170,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -996,6 +1181,7 @@
<child>
<object class="GtkVBox" id="vbox2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1003,31 +1189,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="py_methods">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection5"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="py_methods_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1039,9 +1231,11 @@
<child>
<object class="GtkButton" id="py_methods_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1053,6 +1247,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1061,6 +1256,7 @@
<child type="tab">
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Methods</property>
</object>
<packing>
@@ -1070,6 +1266,7 @@
<child>
<object class="GtkVBox" id="vbox3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1077,31 +1274,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="py_constvars">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection6"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="py_constvars_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1113,9 +1316,11 @@
<child>
<object class="GtkButton" id="py_constvars_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1127,6 +1332,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1138,6 +1344,7 @@
<child type="tab">
<object class="GtkLabel" id="label4">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Constants/Variables</property>
</object>
<packing>
@@ -1147,6 +1354,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1158,6 +1367,7 @@
<child type="tab">
<object class="GtkLabel" id="label80">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Python Class</property>
</object>
<packing>
@@ -1168,21 +1378,25 @@
<child>
<object class="GtkVBox" id="vbox_javascript">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">6</property>
<child>
<object class="GtkFrame" id="frame_javascript">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkTable" id="table1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="n_rows">4</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
@@ -1190,6 +1404,7 @@
<child>
<object class="GtkLabel" id="label5">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Name:</property>
</object>
<packing>
@@ -1211,6 +1426,7 @@
<child>
<object class="GtkLabel" id="label7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source/Header Headings:</property>
</object>
@@ -1224,9 +1440,11 @@
<child>
<object class="GtkCheckButton" id="js_headings">
<property name="label" translatable="yes">Author/Date/Time</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
@@ -1242,6 +1460,7 @@
<object class="GtkLabel" id="lbl_js_base">
<property name="visible">True</property>
<property name="sensitive">False</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Base Class:</property>
</object>
<packing>
@@ -1270,6 +1489,7 @@
<child>
<object class="GtkCheckButton" id="js_is_subclass">
<property name="label" translatable="yes">is Sub-Class</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -1285,6 +1505,7 @@
<child>
<object class="GtkLabel" id="label23">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Initializer Arguments:</property>
</object>
<packing>
@@ -1335,6 +1556,7 @@
<child type="label">
<object class="GtkLabel" id="label8">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">General Class Properties</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -1344,17 +1566,20 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
@@ -1364,6 +1589,7 @@
<child>
<object class="GtkVBox" id="vbox4">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1371,31 +1597,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="js_methods">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection7"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="js_methods_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1407,9 +1639,11 @@
<child>
<object class="GtkButton" id="js_methods_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1421,6 +1655,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1429,6 +1664,7 @@
<child type="tab">
<object class="GtkLabel" id="label12">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Methods</property>
</object>
<packing>
@@ -1438,6 +1674,7 @@
<child>
<object class="GtkVBox" id="vbox5">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1445,31 +1682,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="js_variables">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection8"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="js_variables_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1481,9 +1724,11 @@
<child>
<object class="GtkButton" id="js_variables_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1495,6 +1740,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1506,6 +1752,7 @@
<child type="tab">
<object class="GtkLabel" id="label14">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Variables</property>
</object>
<packing>
@@ -1516,6 +1763,7 @@
<child>
<object class="GtkVBox" id="vbox642">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1523,31 +1771,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="js_imports">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection9"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox9">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="js_imports_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1559,9 +1813,11 @@
<child>
<object class="GtkButton" id="js_imports_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1573,6 +1829,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1584,6 +1841,7 @@
<child type="tab">
<object class="GtkLabel" id="label1213">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Imports</property>
</object>
<packing>
@@ -1598,6 +1856,7 @@
<child type="label">
<object class="GtkLabel" id="label15">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Elements</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -1606,6 +1865,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1617,6 +1878,7 @@
<child type="tab">
<object class="GtkLabel" id="label16">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">JavaScript Class</property>
</object>
<packing>
@@ -1627,21 +1889,25 @@
<child>
<object class="GtkVBox" id="vbox_vala">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">6</property>
<child>
<object class="GtkFrame" id="frame_vala">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment4">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkTable" id="table2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="n_rows">3</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
@@ -1649,6 +1915,7 @@
<child>
<object class="GtkLabel" id="label6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Name:</property>
</object>
<packing>
@@ -1670,6 +1937,7 @@
<child>
<object class="GtkLabel" id="lbl_vala_base">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Base Class:</property>
</object>
<packing>
@@ -1696,6 +1964,7 @@
<child>
<object class="GtkLabel" id="label41">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Scope:</property>
</object>
<packing>
@@ -1708,6 +1977,7 @@
<child>
<object class="GtkComboBox" id="vala_class_scope">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="model">model3</property>
<child>
<object class="GtkCellRendererText" id="renderer2"/>
@@ -1725,6 +1995,7 @@
<child>
<object class="GtkLabel" id="label17">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source/Header Headings:</property>
</object>
@@ -1738,9 +2009,11 @@
<child>
<object class="GtkCheckButton" id="vala_headings">
<property name="label" translatable="yes">Author/Date/Time</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
@@ -1772,6 +2045,7 @@
<child type="label">
<object class="GtkLabel" id="label19">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">General Class Properties</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -1781,17 +2055,20 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame3">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment9">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
@@ -1801,6 +2078,7 @@
<child>
<object class="GtkVBox" id="vbox7">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1808,31 +2086,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="vala_methods">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection10"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox10">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="vala_methods_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1844,9 +2128,11 @@
<child>
<object class="GtkButton" id="vala_methods_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1858,6 +2144,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1866,6 +2153,7 @@
<child type="tab">
<object class="GtkLabel" id="label20">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Methods</property>
</object>
<packing>
@@ -1875,6 +2163,7 @@
<child>
<object class="GtkVBox" id="vbox11">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1882,31 +2171,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="vala_properties">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection11"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox11">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="vala_properties_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1918,9 +2213,11 @@
<child>
<object class="GtkButton" id="vala_properties_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1932,6 +2229,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -1943,6 +2241,7 @@
<child type="tab">
<object class="GtkLabel" id="label21">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Properties</property>
</object>
<packing>
@@ -1953,6 +2252,7 @@
<child>
<object class="GtkVBox" id="vbox14">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">8</property>
<property name="spacing">6</property>
<child>
@@ -1960,31 +2260,37 @@
<property name="height_request">100</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hscrollbar_policy">automatic</property>
- <property name="vscrollbar_policy">automatic</property>
<property name="shadow_type">in</property>
<child>
<object class="GtkTreeView" id="vala_signals">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection" id="treeview-selection12"/>
+ </child>
</object>
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkHButtonBox" id="hbuttonbox12">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">6</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="vala_signals_remove">
<property name="label">gtk-remove</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -1996,9 +2302,11 @@
<child>
<object class="GtkButton" id="vala_signals_add">
<property name="label">gtk-add</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
@@ -2010,6 +2318,7 @@
</object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -2021,6 +2330,7 @@
<child type="tab">
<object class="GtkLabel" id="label22">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Signals</property>
</object>
<packing>
@@ -2035,6 +2345,7 @@
<child type="label">
<object class="GtkLabel" id="label24">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Class Elements</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -2043,6 +2354,8 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
@@ -2054,6 +2367,7 @@
<child type="tab">
<object class="GtkLabel" id="label25">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">Vala Class</property>
</object>
<packing>
@@ -2063,13 +2377,16 @@
</child>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkTable" id="table4">
<property name="visible">True</property>
- <property name="n_rows">4</property>
+ <property name="can_focus">False</property>
+ <property name="n_rows">6</property>
<property name="n_columns">4</property>
<property name="column_spacing">5</property>
<property name="row_spacing">5</property>
@@ -2090,6 +2407,7 @@
<child>
<object class="GtkLabel" id="label18">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Author Email Address:</property>
</object>
@@ -2119,6 +2437,7 @@
<child>
<object class="GtkLabel" id="label26">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Author Name:</property>
</object>
@@ -2132,6 +2451,7 @@
<child>
<object class="GtkComboBox" id="license">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="model">model2</property>
<child>
<object class="GtkCellRendererText" id="renderer3"/>
@@ -2151,6 +2471,7 @@
<child>
<object class="GtkLabel" id="label30">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">License:</property>
</object>
@@ -2164,6 +2485,7 @@
<child>
<object class="GtkLabel" id="label31">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Header File:</property>
</object>
@@ -2175,6 +2497,7 @@
<child>
<object class="GtkHBox" id="hbox2">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">4</property>
<child>
<object class="GtkEntry" id="header_file">
@@ -2183,6 +2506,8 @@
<property name="activates_default">True</property>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -2196,6 +2521,7 @@
<child>
<object class="GtkLabel" id="label32">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="xalign">1</property>
<property name="label" translatable="yes">Source File:</property>
</object>
@@ -2209,6 +2535,7 @@
<child>
<object class="GtkHBox" id="hbox6">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="spacing">4</property>
<child>
<object class="GtkEntry" id="source_file">
@@ -2217,6 +2544,8 @@
<property name="activates_default">True</property>
</object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
@@ -2229,114 +2558,75 @@
<property name="y_options">GTK_FILL</property>
</packing>
</child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkHBox" id="hbox1">
- <property name="visible">True</property>
- <property name="spacing">12</property>
<child>
<object class="GtkCheckButton" id="add_project">
- <property name="label" translatable="yes">Add to Project</property>
+ <property name="label" translatable="yes">Add to Project Target:</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">False</property>
+ <property name="can_focus">True</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
+ <property name="xalign">1</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="position">0</property>
+ <property name="top_attach">4</property>
+ <property name="bottom_attach">5</property>
</packing>
</child>
<child>
<object class="GtkCheckButton" id="add_repository">
<property name="label" translatable="yes">Add to Repository</property>
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <property name="can_focus">False</property>
+ <property name="can_focus">True</property>
<property name="receives_default">False</property>
+ <property name="use_action_appearance">False</property>
+ <property name="xalign">1</property>
<property name="draw_indicator">True</property>
</object>
<packing>
- <property name="position">1</property>
+ <property name="top_attach">5</property>
+ <property name="bottom_attach">6</property>
</packing>
</child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="position">2</property>
- </packing>
- </child>
- </object>
- <packing>
- <property name="position">1</property>
- </packing>
- </child>
- <child internal-child="action_area">
- <object class="GtkHButtonBox" id="dialog-action_area3">
- <property name="visible">True</property>
- <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_ENTER_NOTIFY_MASK</property>
- <property name="layout_style">end</property>
- <child>
- <object class="GtkButton" id="cancel_button">
- <property name="label">gtk-cancel</property>
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="can_default">True</property>
- <property name="receives_default">False</property>
- <property name="use_stock">True</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkButton" id="create_button">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="can_default">True</property>
- <property name="has_default">True</property>
- <property name="receives_default">False</property>
<child>
- <object class="GtkHBox" id="hbox3">
+ <object class="AnjutaPmChooserButton" id="add_project_parent">
+ <property name="use_action_appearance">False</property>
<property name="visible">True</property>
- <child>
- <object class="GtkImage" id="image1">
- <property name="visible">True</property>
- <property name="stock">gtk-save</property>
- </object>
- <packing>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkLabel" id="label33">
- <property name="visible">True</property>
- <property name="label" translatable="yes">Create</property>
- </object>
- <packing>
- <property name="position">1</property>
- </packing>
- </child>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
</object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">4</property>
+ <property name="top_attach">4</property>
+ <property name="bottom_attach">5</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
</child>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
- <property name="pack_type">end</property>
- <property name="position">0</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
</packing>
</child>
</object>
diff --git a/plugins/class-gen/anjuta-class-gen.plugin.in b/plugins/class-gen/anjuta-class-gen.plugin.in
index 90a4558..32d1bb5 100644
--- a/plugins/class-gen/anjuta-class-gen.plugin.in
+++ b/plugins/class-gen/anjuta-class-gen.plugin.in
@@ -4,6 +4,7 @@ _Description=Anjuta Class Generator Plugin
Location=anjuta-class-gen:AnjutaClassGenPlugin
Icon=anjuta-class-gen-plugin-48.png
Interfaces=IAnjutaWizard
+Dependencies=anjuta-project-manager:ProjectManagerPlugin
UserActivatable=no
[Wizard]
diff --git a/plugins/class-gen/plugin.c b/plugins/class-gen/plugin.c
index 02fb618..6a40c7f 100644
--- a/plugins/class-gen/plugin.c
+++ b/plugins/class-gen/plugin.c
@@ -50,7 +50,7 @@ project_root_added (AnjutaPlugin *plugin,
cg_plugin = ANJUTA_PLUGIN_CLASS_GEN (plugin);
root_uri = g_value_get_string (value);
-
+
if (root_uri)
{
gchar *root_dir = anjuta_util_get_local_path_from_uri (root_uri);
@@ -71,7 +71,7 @@ project_root_removed (AnjutaPlugin *plugin,
{
AnjutaClassGenPlugin *cg_plugin;
cg_plugin = ANJUTA_PLUGIN_CLASS_GEN (plugin);
-
+
if (cg_plugin->top_dir)
g_free(cg_plugin->top_dir);
cg_plugin->top_dir = NULL;
@@ -81,13 +81,13 @@ static gboolean
activate_plugin (AnjutaPlugin *plugin)
{
AnjutaClassGenPlugin *cg_plugin;
-
+
DEBUG_PRINT ("%s", "AnjutaClassGenPlugin: Activating ClassGen plugin...");
cg_plugin = ANJUTA_PLUGIN_CLASS_GEN (plugin);
cg_plugin->prefs = anjuta_shell_get_preferences (plugin->shell, NULL);
-
+
g_return_val_if_fail (cg_plugin->prefs != NULL, FALSE);
-
+
cg_plugin->top_dir = NULL;
/* Check if autogen is present */
@@ -117,10 +117,10 @@ deactivate_plugin (AnjutaPlugin *plugin)
AnjutaClassGenPlugin *cg_plugin;
cg_plugin = ANJUTA_PLUGIN_CLASS_GEN (plugin);
DEBUG_PRINT ("%s", "AnjutaClassGenPlugin: Deactivating ClassGen plugin ...");
-
+
/* Remove watches */
anjuta_plugin_remove_watch (plugin, cg_plugin->root_watch_id, TRUE);
-
+
return TRUE;
}
@@ -146,7 +146,7 @@ finalize (GObject *obj)
}
static void
-class_gen_plugin_class_init (GObjectClass *klass)
+class_gen_plugin_class_init (GObjectClass *klass)
{
AnjutaPluginClass *plugin_class = ANJUTA_PLUGIN_CLASS (klass);
@@ -173,51 +173,49 @@ cg_plugin_add_to_project (AnjutaClassGenPlugin *plugin,
const gchar *header_file,
const gchar *source_file,
gchar **new_header_file,
- gchar **new_source_file)
+ gchar **new_source_file,
+ GFile *target)
{
IAnjutaProjectManager *manager;
- GList *filenames = NULL;
- GList *added_files;
- GFile *file;
+ GFile *header = NULL;
+ GFile *source;
gboolean result;
manager = anjuta_shell_get_interface (ANJUTA_PLUGIN (plugin)->shell,
IAnjutaProjectManager, NULL);
-
- if (manager == NULL)
+
+ if (manager == NULL)
return FALSE;
- if (header_file != NULL) filenames = g_list_append (filenames, g_path_get_basename (header_file));
- filenames = g_list_append (filenames, g_path_get_basename (source_file));
- file = g_file_new_for_path (plugin->top_dir);
- added_files = ianjuta_project_manager_add_sources (manager, filenames,
- file, NULL);
- g_object_unref (file);
- g_list_foreach (filenames, (GFunc)g_free, NULL);
- g_list_free (filenames);
+ source = ianjuta_project_manager_add_source_quiet (manager, source_file,
+ target, NULL);
+ if (header_file) header = ianjuta_project_manager_add_source_quiet (manager, header_file,
+ target, NULL);
- result = g_list_length (added_files) == ((header_file == NULL) ? 1 : 2);
+ result = source != NULL;
if (result)
{
+ *new_source_file = g_file_get_path(source);
+ g_object_unref (source);
+ *new_header_file = NULL;
/*
* Check if we're dealing with a programming language not having header
* files.
*/
- if (header_file == NULL)
+ if (header_file != NULL)
{
- *new_header_file = NULL;
- *new_source_file = g_file_get_path((GFile *)added_files->data);
- }
- else
- {
- *new_header_file = g_file_get_path((GFile *)added_files->data);
- *new_source_file = g_file_get_path((GFile *)g_list_next (added_files)->data);
+ if (header == NULL)
+ {
+ result = FALSE;
+ }
+ else
+ {
+ *new_header_file = g_file_get_path(header);
+ g_object_unref (header);
+ }
}
}
- g_list_foreach (added_files, (GFunc)g_object_unref, NULL);
- g_list_free (added_files);
-
return result;
}
@@ -270,7 +268,7 @@ cg_plugin_load (AnjutaClassGenPlugin *plugin,
gboolean result;
docman = anjuta_shell_get_interface (ANJUTA_PLUGIN (plugin)->shell,
- IAnjutaDocumentManager, NULL);
+ IAnjutaDocumentManager, NULL);
if(g_file_get_contents(file, &contents, NULL, error) == FALSE)
return FALSE;
@@ -287,10 +285,10 @@ cg_plugin_load (AnjutaClassGenPlugin *plugin,
if(!error || *error == NULL)
result = TRUE;
}
-
+
g_free(contents);
g_free(name);
-
+
return result;
}
@@ -309,7 +307,7 @@ cg_plugin_generator_created_cb (CgGenerator *generator,
loader = anjuta_shell_get_interface (ANJUTA_PLUGIN (plugin)->shell,
IAnjutaFileLoader, NULL);
-
+
if (cg_window_get_add_to_project (plugin->window))
{
GFile* header = NULL;
@@ -335,7 +333,7 @@ cg_plugin_generator_created_cb (CgGenerator *generator,
{
cg_plugin_add_to_repository (plugin, header, source);
}
-
+
manager = anjuta_shell_get_interface (ANJUTA_PLUGIN (plugin)->shell, IAnjutaProjectManager, NULL);
if (manager)
{
@@ -397,10 +395,12 @@ cg_plugin_window_response_cb (G_GNUC_UNUSED GtkDialog *dialog,
{
if (cg_window_get_add_to_project (plugin->window))
{
+ GFile *target = cg_window_get_selected_target (plugin->window);
result = cg_plugin_add_to_project (
plugin, cg_window_get_header_file (plugin->window),
cg_window_get_source_file (plugin->window),
- &header_file, &source_file);
+ &header_file, &source_file,
+ target);
}
else
{
@@ -487,7 +487,8 @@ iwizard_activate (IAnjutaWizard *wiz, G_GNUC_UNUSED GError **err)
gchar *user_name;
gchar *user_email;
gint caps = 0;
-
+ gboolean has_project;
+
cg_plugin = ANJUTA_PLUGIN_CLASS_GEN (wiz);
if (cg_plugin->window != NULL)
@@ -498,7 +499,7 @@ iwizard_activate (IAnjutaWizard *wiz, G_GNUC_UNUSED GError **err)
user_name = g_strdup(g_get_real_name ());
/* FIXME: */
user_email = anjuta_util_get_user_mail();
-
+
if (user_name != NULL)
cg_window_set_author (cg_plugin->window, user_name);
@@ -514,15 +515,16 @@ iwizard_activate (IAnjutaWizard *wiz, G_GNUC_UNUSED GError **err)
IAnjutaProjectManager *manager =
anjuta_shell_get_interface (ANJUTA_PLUGIN (wiz)->shell,
IAnjutaProjectManager, NULL);
- if (manager)
+ if (manager)
+ {
caps = ianjuta_project_manager_get_capabilities (manager, NULL);
+ cg_window_set_project_model (cg_plugin->window, manager);
+ }
}
- if((caps & ANJUTA_PROJECT_CAN_ADD_SOURCE) == FALSE)
- {
- cg_window_set_add_to_project (cg_plugin->window, FALSE);
- cg_window_enable_add_to_project (cg_plugin->window, FALSE);
- }
+ has_project = (caps & ANJUTA_PROJECT_CAN_ADD_SOURCE) ? TRUE : FALSE;
+ cg_window_set_add_to_project (cg_plugin->window, has_project);
+ cg_window_enable_add_to_project (cg_plugin->window, has_project);
/* TODO: Check whether the project is in version control, and enable
* "add to repository" button respectively. */
diff --git a/plugins/class-gen/window.c b/plugins/class-gen/window.c
index d062d8c..5c19326 100644
--- a/plugins/class-gen/window.c
+++ b/plugins/class-gen/window.c
@@ -23,6 +23,7 @@
#include "element-editor.h"
#include <libanjuta/anjuta-plugin.h>
+#include <libanjuta/interfaces/ianjuta-project-chooser.h>
#include <stdlib.h>
#include <glib.h>
@@ -47,7 +48,7 @@ struct _CgWindowPrivate
{
GtkBuilder *bxml;
GtkWidget *window;
-
+
CgElementEditor *editor_cc;
CgElementEditor *editor_go_members;
@@ -177,7 +178,7 @@ cg_window_browse_button_clicked_cb (GtkButton *button,
gchar *filename;
entry = GTK_WIDGET (user_data);
-
+
dialog = GTK_FILE_CHOOSER_DIALOG (
gtk_file_chooser_dialog_new (
"Select A File", /* TODO: Better context for caption */
@@ -199,7 +200,7 @@ cg_window_browse_button_clicked_cb (GtkButton *button,
gtk_entry_set_text (GTK_ENTRY (entry), filename);
g_free (filename);
}
-
+
gtk_widget_destroy (GTK_WIDGET (dialog));
}
#endif
@@ -221,7 +222,7 @@ cg_window_fetch_string (CgWindow *window,
else if (GTK_IS_COMBO_BOX (widget))
{
GtkTreeIter iter;
-
+
if (gtk_combo_box_get_active_iter (GTK_COMBO_BOX (widget), &iter))
{
GtkTreeModel *model;
@@ -229,9 +230,9 @@ cg_window_fetch_string (CgWindow *window,
model = gtk_combo_box_get_model (GTK_COMBO_BOX (widget));
g_return_val_if_fail (GTK_IS_LIST_STORE (model), NULL);
-
+
gtk_tree_model_get (model, &iter, 0, &text, -1);
-
+
return text;
}
else
@@ -249,12 +250,12 @@ cg_window_fetch_integer (CgWindow *window,
{
GtkWidget *widget;
CgWindowPrivate *priv;
-
+
priv = CG_WINDOW_PRIVATE(window);
widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, id));
-
+
g_return_val_if_fail(widget != NULL, 0);
-
+
if (GTK_IS_SPIN_BUTTON(widget))
return gtk_spin_button_get_value_as_int( GTK_SPIN_BUTTON( widget));
else if (GTK_IS_ENTRY (widget))
@@ -271,12 +272,12 @@ cg_window_fetch_boolean (CgWindow *window,
{
GtkWidget *widget;
CgWindowPrivate *priv;
-
+
priv = CG_WINDOW_PRIVATE (window);
widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, id));
-
+
g_return_val_if_fail (widget != NULL, FALSE);
-
+
if (GTK_IS_TOGGLE_BUTTON (widget))
return gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget));
else
@@ -325,9 +326,9 @@ cg_window_validate_cc (CgWindow *window)
{
CgWindowPrivate *priv;
priv = CG_WINDOW_PRIVATE(window);
-
+
if (priv->validator != NULL) g_object_unref (G_OBJECT (priv->validator));
-
+
priv->validator = cg_validator_new (
GTK_WIDGET (gtk_builder_get_object (priv->bxml, "create_button")),
GTK_ENTRY (gtk_builder_get_object (priv->bxml, "cc_name")),
@@ -340,9 +341,9 @@ cg_window_validate_go (CgWindow *window)
{
CgWindowPrivate *priv;
priv = CG_WINDOW_PRIVATE (window);
-
+
if (priv->validator != NULL) g_object_unref (G_OBJECT (priv->validator));
-
+
priv->validator = cg_validator_new (
GTK_WIDGET (gtk_builder_get_object (priv->bxml, "create_button")),
GTK_ENTRY (gtk_builder_get_object (priv->bxml, "go_name")),
@@ -358,9 +359,9 @@ cg_window_validate_py (CgWindow *window)
{
CgWindowPrivate *priv;
priv = CG_WINDOW_PRIVATE (window);
-
+
if (priv->validator != NULL) g_object_unref (G_OBJECT (priv->validator));
-
+
priv->validator = cg_validator_new (
GTK_WIDGET (gtk_builder_get_object (priv->bxml, "create_button")),
GTK_ENTRY (gtk_builder_get_object (priv->bxml, "py_name")), NULL);
@@ -455,27 +456,54 @@ cg_window_class_name_to_file_name (const gchar *class_name)
}
static void
+cg_window_add_project_parent_changed_cb (GtkWidget *project_combo, gpointer user_data)
+{
+ CgWindow *window;
+ CgWindowPrivate *priv;
+ gboolean active = TRUE;
+ GtkWidget *widget;
+
+ window = CG_WINDOW (user_data);
+ priv = CG_WINDOW_PRIVATE (window);
+
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project"));
+ if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
+ {
+ GFile *file;
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project_parent"));
+
+ file = ianjuta_project_chooser_get_selected (IANJUTA_PROJECT_CHOOSER (widget), NULL);
+ active = file != NULL;
+ }
+
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "create_button"));
+ gtk_widget_set_sensitive (widget, active);
+}
+
+static void
cg_window_add_project_toggled_cb (GtkToggleButton *button,
gpointer user_data)
{
CgWindow *window;
CgWindowPrivate *priv;
-
+ GtkWidget *widget;
+ gboolean sensitive;
+
window = CG_WINDOW (user_data);
priv = CG_WINDOW_PRIVATE (window);
- if (gtk_toggle_button_get_active (button) == FALSE)
+ sensitive = gtk_toggle_button_get_active (button);
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_repository"));
+ gtk_widget_set_sensitive (widget, sensitive);
+ if (!sensitive)
{
- GtkWidget* widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_repository"));
- gtk_widget_set_sensitive (widget, FALSE);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(widget),
FALSE);
}
- else
- {
- gtk_widget_set_sensitive (GTK_WIDGET (gtk_builder_get_object (
- priv->bxml, "add_repository")), TRUE);
- }
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project_parent"));
+ gtk_widget_set_sensitive (widget, sensitive);
+
+ cg_window_add_project_parent_changed_cb (NULL, window);
}
static void
@@ -503,10 +531,10 @@ cg_window_cc_name_changed_cb (GtkEntry *entry,
str_fileheader = g_strconcat (str_filebase, ".h", NULL);
str_filesource = g_strconcat (str_filebase, ".cc", NULL);
g_free (str_filebase);
-
+
gtk_entry_set_text (GTK_ENTRY (file_header), str_fileheader);
gtk_entry_set_text (GTK_ENTRY (file_source), str_filesource);
-
+
g_free (str_fileheader);
g_free (str_filesource);
}
@@ -535,7 +563,7 @@ cg_window_go_name_changed_cb (GtkEntry *entry,
window = CG_WINDOW (user_data);
priv = CG_WINDOW_PRIVATE (window);
-
+
type_prefix = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "go_prefix"));
type_name = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "go_type"));
func_prefix = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "go_func_prefix"));
@@ -550,19 +578,19 @@ cg_window_go_name_changed_cb (GtkEntry *entry,
gtk_entry_set_text (GTK_ENTRY (type_prefix), str_type_prefix);
gtk_entry_set_text (GTK_ENTRY (type_name), str_type_name);
gtk_entry_set_text (GTK_ENTRY (func_prefix), str_func_prefix);
-
+
g_free (str_type_prefix);
g_free (str_type_name);
g_free (str_func_prefix);
-
+
str_filebase = cg_window_class_name_to_file_name (name);
str_fileheader = g_strconcat (str_filebase, ".h", NULL);
str_filesource = g_strconcat (str_filebase, ".c", NULL);
g_free (str_filebase);
-
+
gtk_entry_set_text (GTK_ENTRY (file_header), str_fileheader);
gtk_entry_set_text (GTK_ENTRY (file_source), str_filesource);
-
+
g_free (str_fileheader);
g_free (str_filesource);
}
@@ -591,10 +619,10 @@ cg_window_dynamic_name_changed_cb (GtkEntry *entry,
str_filesource = g_strconcat (str_filebase, file_ending, NULL);
g_free (str_filebase);
-
+
gtk_entry_set_text (GTK_ENTRY (file_header), str_filesource);
gtk_entry_set_text (GTK_ENTRY (file_source), str_filesource);
-
+
g_free (str_filesource);
}
@@ -657,7 +685,7 @@ cg_window_associate_browse_button (GladeXML *xml,
{
GtkWidget *button;
GtkWidget *entry;
-
+
button = glade_xml_get_widget (xml, button_id);
entry = glade_xml_get_widget (xml, entry_id);
@@ -698,7 +726,7 @@ cg_window_set_builder (CgWindow *window,
_("Type"), CG_ELEMENT_EDITOR_COLUMN_STRING,
_("Name"), CG_ELEMENT_EDITOR_COLUMN_STRING,
_("Arguments"), CG_ELEMENT_EDITOR_COLUMN_ARGUMENTS);
-
+
priv->editor_go_members = cg_element_editor_new (
GTK_TREE_VIEW (gtk_builder_get_object (priv->bxml, "go_members")),
GTK_BUTTON (gtk_builder_get_object (priv->bxml, "go_members_add")),
@@ -708,7 +736,7 @@ cg_window_set_builder (CgWindow *window,
_("Type"), CG_ELEMENT_EDITOR_COLUMN_STRING,
_("Name"), CG_ELEMENT_EDITOR_COLUMN_STRING,
_("Arguments"), CG_ELEMENT_EDITOR_COLUMN_ARGUMENTS);
-
+
priv->editor_go_properties = cg_element_editor_new(
GTK_TREE_VIEW (gtk_builder_get_object (priv->bxml, "go_properties")),
GTK_BUTTON (gtk_builder_get_object (priv->bxml, "go_properties_add")),
@@ -721,7 +749,7 @@ cg_window_set_builder (CgWindow *window,
_("ParamSpec"), CG_ELEMENT_EDITOR_COLUMN_LIST, GO_PARAMSPEC_LIST,
_("Default"), CG_ELEMENT_EDITOR_COLUMN_STRING,
_("Flags"), CG_ELEMENT_EDITOR_COLUMN_FLAGS, GO_PROPERTY_FLAGS);
-
+
priv->editor_go_signals = cg_element_editor_new(
GTK_TREE_VIEW (gtk_builder_get_object (priv->bxml, "go_signals")),
GTK_BUTTON (gtk_builder_get_object (priv->bxml, "go_signals_add")),
@@ -830,7 +858,7 @@ cg_window_set_builder (CgWindow *window,
G_OBJECT (gtk_builder_get_object (priv->bxml, "top_notebook")),
"switch-page", G_CALLBACK (cg_window_top_notebook_switch_page_cb),
window);
-
+
g_signal_connect (
G_OBJECT (gtk_builder_get_object (priv->bxml, "go_name")), "changed",
G_CALLBACK (cg_window_go_name_changed_cb), window);
@@ -851,6 +879,10 @@ cg_window_set_builder (CgWindow *window,
G_OBJECT (gtk_builder_get_object (priv->bxml, "add_project")), "toggled",
G_CALLBACK (cg_window_add_project_toggled_cb), window);
+ g_signal_connect (
+ G_OBJECT (gtk_builder_get_object (priv->bxml, "add_project_parent")), "changed",
+ G_CALLBACK (cg_window_add_project_parent_changed_cb), window);
+
cg_window_add_project_toggled_cb (GTK_TOGGLE_BUTTON (
gtk_builder_get_object (priv->bxml, "add_project")), window);
@@ -884,7 +916,7 @@ cg_window_go_members_transform_func (GHashTable *table,
name = g_strdup (name + strlen (func_prefix) + 1);
g_hash_table_insert (table, "Name", name);
}
-
+
g_free (func_prefix);
cg_transform_arguments (table, "Arguments", TRUE);
}
@@ -917,12 +949,12 @@ cg_window_go_signals_transform_func (GHashTable *table,
gchar *type;
guint arg_count;
-
+
gchar *gtype_prefix;
gchar *gtype_suffix;
gchar *name;
gchar *self_type;
-
+
window = CG_WINDOW (user_data);
cg_transform_string (table, "Name");
@@ -942,7 +974,7 @@ cg_window_go_signals_transform_func (GHashTable *table,
name = cg_window_fetch_string (window, "go_name");
self_type = g_strconcat (name, "*", NULL);
g_free (name);
-
+
cg_transform_first_argument (table, "Arguments", self_type);
g_free (self_type);
@@ -981,7 +1013,7 @@ static void
cg_window_js_variables_transform_func (GHashTable *table,
G_GNUC_UNUSED gpointer user_data)
{
-
+
cg_transform_string (table, "Name");
}
@@ -1078,7 +1110,7 @@ cg_window_init (CgWindow *window)
priv->bxml = NULL;
priv->window = NULL;
-
+
priv->editor_cc = NULL;
priv->editor_go_members = NULL;
priv->editor_go_properties = NULL;
@@ -1091,16 +1123,16 @@ cg_window_init (CgWindow *window)
priv->editor_vala_methods = NULL;
priv->editor_vala_properties = NULL;
priv->editor_vala_signals = NULL;
-
+
priv->validator = NULL;
}
-static void
+static void
cg_window_finalize (GObject *object)
{
CgWindow *window;
CgWindowPrivate *priv;
-
+
window = CG_WINDOW (object);
priv = CG_WINDOW_PRIVATE (window);
@@ -1169,7 +1201,7 @@ cg_window_set_property (GObject *object,
static void
cg_window_get_property (GObject *object,
guint prop_id,
- GValue *value,
+ GValue *value,
GParamSpec *pspec)
{
CgWindow *window;
@@ -1279,13 +1311,13 @@ cg_window_create_value_heap (CgWindow *window)
NPWValue *value;
GError *error;
gint license_index;
-
+
GtkNotebook *notebook;
gchar *header_file;
gchar *source_file;
- gchar *text;
+ gchar *text;
gchar *base_prefix;
gchar *base_suffix;
@@ -1335,10 +1367,10 @@ cg_window_create_value_heap (CgWindow *window)
value = npw_value_heap_find_value (values, "BaseTypePrefix");
npw_value_set_value (value, base_prefix, NPW_VALID_VALUE);
-
+
value = npw_value_heap_find_value (values, "BaseTypeSuffix");
npw_value_set_value (value, base_suffix, NPW_VALID_VALUE);
-
+
g_free (base_prefix);
g_free (base_suffix);
@@ -1370,7 +1402,7 @@ cg_window_create_value_heap (CgWindow *window)
cg_element_editor_set_value_count (priv->editor_go_members,
"PublicFunctionCount", values,
cg_window_scope_with_args_condition_func, "public");
-
+
cg_element_editor_set_value_count (priv->editor_go_members,
"PublicVariableCount", values,
cg_window_scope_without_args_condition_func, "public");
@@ -1463,16 +1495,16 @@ cg_window_create_value_heap (CgWindow *window)
header_file = cg_window_get_header_file (window) != NULL ? g_path_get_basename (cg_window_get_header_file (window)) : NULL;
source_file = g_path_get_basename (cg_window_get_source_file (window));
-
+
value = npw_value_heap_find_value (values, "HeaderFile");
npw_value_set_value (value, header_file, NPW_VALID_VALUE);
-
+
value = npw_value_heap_find_value (values, "SourceFile");
npw_value_set_value (value, source_file, NPW_VALID_VALUE);
-
+
g_free (header_file);
g_free (source_file);
-
+
return values;
}
@@ -1485,7 +1517,7 @@ cg_window_get_header_template (CgWindow *window)
priv = CG_WINDOW_PRIVATE (window);
notebook = GTK_NOTEBOOK (gtk_builder_get_object (priv->bxml,
"top_notebook"));
-
+
g_return_val_if_fail (GTK_IS_NOTEBOOK (notebook), NULL);
switch(gtk_notebook_get_current_page (notebook))
@@ -1514,7 +1546,7 @@ cg_window_get_header_file(CgWindow *window)
priv = CG_WINDOW_PRIVATE (window);
entry = GTK_ENTRY (gtk_builder_get_object (priv->bxml, "header_file"));
-
+
g_return_val_if_fail (GTK_IS_ENTRY (entry), NULL);
return gtk_widget_get_sensitive (GTK_WIDGET (entry)) == TRUE ? gtk_entry_get_text (entry) : NULL;
}
@@ -1528,7 +1560,7 @@ cg_window_get_source_template(CgWindow *window)
priv = CG_WINDOW_PRIVATE (window);
notebook = GTK_NOTEBOOK (gtk_builder_get_object (priv->bxml,
"top_notebook"));
-
+
g_return_val_if_fail (GTK_IS_NOTEBOOK (notebook), NULL);
switch(gtk_notebook_get_current_page (notebook))
@@ -1557,11 +1589,23 @@ cg_window_get_source_file (CgWindow *window)
priv = CG_WINDOW_PRIVATE (window);
entry = GTK_ENTRY (gtk_builder_get_object (priv->bxml, "source_file"));
-
+
g_return_val_if_fail (GTK_IS_ENTRY (entry), NULL);
return gtk_entry_get_text (entry);
}
+GFile *
+cg_window_get_selected_target (CgWindow *window)
+{
+ CgWindowPrivate *priv;
+ IAnjutaProjectChooser *chooser;
+
+ priv = CG_WINDOW_PRIVATE (window);
+ chooser = IANJUTA_PROJECT_CHOOSER (gtk_builder_get_object (priv->bxml, "add_project_parent"));
+
+ return ianjuta_project_chooser_get_selected (chooser, NULL);
+}
+
void
cg_window_set_add_to_project (CgWindow *window,
gboolean enable)
@@ -1614,23 +1658,38 @@ cg_window_enable_add_to_project (CgWindow *window,
{
CgWindowPrivate *priv;
GtkWidget *widget;
-
+
priv = CG_WINDOW_PRIVATE (window);
widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project"));
-
+ gtk_widget_set_sensitive (widget, enable);
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project_parent"));
gtk_widget_set_sensitive (widget, enable);
}
void
+cg_window_set_project_model (CgWindow *window, IAnjutaProjectManager *manager)
+{
+ CgWindowPrivate *priv;
+ GtkWidget *widget;
+
+ priv = CG_WINDOW_PRIVATE (window);
+ widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_project_parent"));
+ ianjuta_project_chooser_set_project_model (IANJUTA_PROJECT_CHOOSER (widget),
+ IANJUTA_PROJECT_MANAGER (manager),
+ ANJUTA_PROJECT_SOURCE,
+ NULL);
+}
+
+void
cg_window_enable_add_to_repository (CgWindow *window,
gboolean enable)
{
CgWindowPrivate *priv;
GtkWidget *widget;
-
+
priv = CG_WINDOW_PRIVATE (window);
widget = GTK_WIDGET (gtk_builder_get_object (priv->bxml, "add_repository"));
-
+
gtk_widget_set_sensitive (widget, enable);
}
@@ -1640,10 +1699,10 @@ cg_window_set_author (CgWindow *window,
{
CgWindowPrivate* priv;
GtkEntry* entry;
-
+
priv = CG_WINDOW_PRIVATE (window);
entry = GTK_ENTRY(gtk_builder_get_object (priv->bxml, "author_name"));
-
+
gtk_entry_set_text (entry, author);
}
@@ -1653,9 +1712,9 @@ cg_window_set_email (CgWindow *window,
{
CgWindowPrivate* priv;
GtkEntry* entry;
-
+
priv = CG_WINDOW_PRIVATE (window);
entry = GTK_ENTRY(gtk_builder_get_object (priv->bxml, "author_email"));
-
+
gtk_entry_set_text (entry, email);
}
diff --git a/plugins/class-gen/window.h b/plugins/class-gen/window.h
index b169590..5d72d62 100644
--- a/plugins/class-gen/window.h
+++ b/plugins/class-gen/window.h
@@ -26,6 +26,9 @@
#include <glib-object.h>
+#include <libanjuta/interfaces/ianjuta-project-manager.h>
+
+
G_BEGIN_DECLS
#define CG_TYPE_WINDOW (cg_window_get_type ())
@@ -61,6 +64,7 @@ const gchar *cg_window_get_header_template (CgWindow *window);
const gchar *cg_window_get_header_file (CgWindow *window);
const gchar *cg_window_get_source_template (CgWindow *window);
const gchar *cg_window_get_source_file (CgWindow *window);
+GFile *cg_window_get_selected_target (CgWindow *window);
void cg_window_set_add_to_project (CgWindow *window,
gboolean enable);
@@ -71,6 +75,8 @@ gboolean cg_window_get_add_to_repository(CgWindow *window);
void cg_window_enable_add_to_project (CgWindow *window,
gboolean enable);
+void cg_window_set_project_model (CgWindow *window,
+ IAnjutaProjectManager *manager);
void cg_window_enable_add_to_repository (CgWindow *window,
gboolean enable);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]