~ubuntu-branches/ubuntu/vivid/ardour/vivid-proposed

« back to all changes in this revision

Viewing changes to libs/gtkmm2/gtk/gtkmm/fileselection.cc

  • Committer: Package Import Robot
  • Author(s): Felipe Sateler, Jaromír Mikeš, Felipe Sateler
  • Date: 2014-05-22 14:39:25 UTC
  • mfrom: (29 sid)
  • mto: This revision was merged to the branch mainline in revision 30.
  • Revision ID: package-import@ubuntu.com-20140522143925-vwqfo9287pmkrroe
Tags: 1:2.8.16+git20131003-3
* Team upload

[ Jaromír Mikeš ]
* Add -dbg package

[ Felipe Sateler ]
* Upload to experimental

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Generated by gtkmmproc -- DO NOT MODIFY!
 
2
 
 
3
#include <gtkmm/fileselection.h>
 
4
#include <gtkmm/private/fileselection_p.h>
 
5
 
 
6
// -*- c++ -*-
 
7
/* $Id$ */
 
8
 
 
9
/* Copyright 1998-2002 The gtkmm Development Team
 
10
 *
 
11
 * This library is free software; you can redistribute it and/or
 
12
 * modify it under the terms of the GNU Library General Public
 
13
 * License as published by the Free Software Foundation; either
 
14
 * version 2 of the License, or (at your option) any later version.
 
15
 *
 
16
 * This library is distributed in the hope that it will be useful,
 
17
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
18
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
19
 * Library General Public License for more details.
 
20
 *
 
21
 * You should have received a copy of the GNU Library General Public
 
22
 * License along with this library; if not, write to the Free
 
23
 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
24
 */
 
25
 
 
26
#include <gtk/gtkfilesel.h>
 
27
#include <gtkmm/entry.h>
 
28
#include <gtkmm/label.h>
 
29
#include <gtkmm/box.h>
 
30
#include <gtkmm/button.h>
 
31
 
 
32
 
 
33
namespace Gtk
 
34
{
 
35
 
 
36
FileSelection::FileSelection()
 
37
:
 
38
  Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
 
39
  Gtk::Dialog(Glib::ConstructParams(fileselection_class_.init(), "title",(char*) 0, (char*) 0))
 
40
{}
 
41
 
 
42
} // namespace Gtk
 
43
 
 
44
 
 
45
namespace
 
46
{
 
47
} // anonymous namespace
 
48
 
 
49
 
 
50
namespace Glib
 
51
{
 
52
 
 
53
Gtk::FileSelection* wrap(GtkFileSelection* object, bool take_copy)
 
54
{
 
55
  return dynamic_cast<Gtk::FileSelection *> (Glib::wrap_auto ((GObject*)(object), take_copy));
 
56
}
 
57
 
 
58
} /* namespace Glib */
 
59
 
 
60
namespace Gtk
 
61
{
 
62
 
 
63
 
 
64
/* The *_Class implementation: */
 
65
 
 
66
const Glib::Class& FileSelection_Class::init()
 
67
{
 
68
  if(!gtype_) // create the GType if necessary
 
69
  {
 
70
    // Glib::Class has to know the class init function to clone custom types.
 
71
    class_init_func_ = &FileSelection_Class::class_init_function;
 
72
 
 
73
    // This is actually just optimized away, apparently with no harm.
 
74
    // Make sure that the parent type has been created.
 
75
    //CppClassParent::CppObjectType::get_type();
 
76
 
 
77
    // Create the wrapper type, with the same class/instance size as the base type.
 
78
    register_derived_type(gtk_file_selection_get_type());
 
79
 
 
80
    // Add derived versions of interfaces, if the C type implements any interfaces:
 
81
  }
 
82
 
 
83
  return *this;
 
84
}
 
85
 
 
86
void FileSelection_Class::class_init_function(void* g_class, void* class_data)
 
87
{
 
88
  BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
 
89
  CppClassParent::class_init_function(klass, class_data);
 
90
 
 
91
}
 
92
 
 
93
 
 
94
Glib::ObjectBase* FileSelection_Class::wrap_new(GObject* o)
 
95
{
 
96
  return new FileSelection((GtkFileSelection*)(o)); //top-level windows can not be manage()ed.
 
97
 
 
98
}
 
99
 
 
100
 
 
101
/* The implementation: */
 
102
 
 
103
FileSelection::FileSelection(const Glib::ConstructParams& construct_params)
 
104
:
 
105
  Gtk::Dialog(construct_params)
 
106
{
 
107
  }
 
108
 
 
109
FileSelection::FileSelection(GtkFileSelection* castitem)
 
110
:
 
111
  Gtk::Dialog((GtkDialog*)(castitem))
 
112
{
 
113
  }
 
114
 
 
115
FileSelection::~FileSelection()
 
116
{
 
117
  destroy_();
 
118
}
 
119
 
 
120
FileSelection::CppClassType FileSelection::fileselection_class_; // initialize static member
 
121
 
 
122
GType FileSelection::get_type()
 
123
{
 
124
  return fileselection_class_.init().get_type();
 
125
}
 
126
 
 
127
GType FileSelection::get_base_type()
 
128
{
 
129
  return gtk_file_selection_get_type();
 
130
}
 
131
 
 
132
 
 
133
FileSelection::FileSelection(const Glib::ustring& title)
 
134
:
 
135
  Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
 
136
  Gtk::Dialog(Glib::ConstructParams(fileselection_class_.init(), "title", title.c_str(), (char*) 0))
 
137
{
 
138
  }
 
139
 
 
140
void FileSelection::set_filename(const std::string& filename)
 
141
{
 
142
  gtk_file_selection_set_filename(gobj(), (filename).c_str());
 
143
}
 
144
 
 
145
std::string FileSelection::get_filename() const
 
146
{
 
147
  return std::string(gtk_file_selection_get_filename(const_cast<GtkFileSelection*>(gobj())));
 
148
}
 
149
 
 
150
void FileSelection::complete(const Glib::ustring& pattern)
 
151
{
 
152
  gtk_file_selection_complete(gobj(), pattern.c_str());
 
153
}
 
154
 
 
155
void FileSelection::show_fileop_buttons()
 
156
{
 
157
  gtk_file_selection_show_fileop_buttons(gobj());
 
158
}
 
159
 
 
160
void FileSelection::hide_fileop_buttons()
 
161
{
 
162
  gtk_file_selection_hide_fileop_buttons(gobj());
 
163
}
 
164
 
 
165
Glib::ArrayHandle<std::string> FileSelection::get_selections() const
 
166
{
 
167
  return Glib::ArrayHandle<std::string>(gtk_file_selection_get_selections(const_cast<GtkFileSelection*>(gobj())), Glib::OWNERSHIP_DEEP);
 
168
}
 
169
 
 
170
void FileSelection::set_select_multiple(bool select_multiple)
 
171
{
 
172
  gtk_file_selection_set_select_multiple(gobj(), static_cast<int>(select_multiple));
 
173
}
 
174
 
 
175
bool FileSelection::get_select_multiple() const
 
176
{
 
177
  return gtk_file_selection_get_select_multiple(const_cast<GtkFileSelection*>(gobj()));
 
178
}
 
179
 
 
180
TreeView* FileSelection::get_dir_list()
 
181
{
 
182
  return Glib::wrap((GtkTreeView*)(gobj()->dir_list));
 
183
}
 
184
 
 
185
const TreeView* FileSelection::get_dir_list() const
 
186
{
 
187
  return Glib::wrap((GtkTreeView*)(gobj()->dir_list));
 
188
}
 
189
 
 
190
TreeView* FileSelection::get_file_list()
 
191
{
 
192
  return Glib::wrap((GtkTreeView*)(gobj()->file_list));
 
193
}
 
194
 
 
195
const TreeView* FileSelection::get_file_list() const
 
196
{
 
197
  return Glib::wrap((GtkTreeView*)(gobj()->file_list));
 
198
}
 
199
 
 
200
OptionMenu* FileSelection::get_history_pulldown()
 
201
{
 
202
  return Glib::wrap((GtkOptionMenu*)(gobj()->history_pulldown));
 
203
}
 
204
 
 
205
const OptionMenu* FileSelection::get_history_pulldown() const
 
206
{
 
207
  return Glib::wrap((GtkOptionMenu*)(gobj()->history_pulldown));
 
208
}
 
209
 
 
210
Entry* FileSelection::get_selection_entry()
 
211
{
 
212
  return Glib::wrap((GtkEntry*)(gobj()->selection_entry));
 
213
}
 
214
 
 
215
const Entry* FileSelection::get_selection_entry() const
 
216
{
 
217
  return Glib::wrap((GtkEntry*)(gobj()->selection_entry));
 
218
}
 
219
 
 
220
Label* FileSelection::get_selection_text()
 
221
{
 
222
  return Glib::wrap((GtkLabel*)(gobj()->selection_text));
 
223
}
 
224
 
 
225
const Label* FileSelection::get_selection_text() const
 
226
{
 
227
  return Glib::wrap((GtkLabel*)(gobj()->selection_text));
 
228
}
 
229
 
 
230
VBox* FileSelection::get_main_vbox()
 
231
{
 
232
  return Glib::wrap((GtkVBox*)(gobj()->main_vbox));
 
233
}
 
234
 
 
235
const VBox* FileSelection::get_main_vbox() const
 
236
{
 
237
  return Glib::wrap((GtkVBox*)(gobj()->main_vbox));
 
238
}
 
239
 
 
240
Button* FileSelection::get_ok_button()
 
241
{
 
242
  return Glib::wrap((GtkButton*)(gobj()->ok_button));
 
243
}
 
244
 
 
245
const Button* FileSelection::get_ok_button() const
 
246
{
 
247
  return Glib::wrap((GtkButton*)(gobj()->ok_button));
 
248
}
 
249
 
 
250
Button* FileSelection::get_cancel_button()
 
251
{
 
252
  return Glib::wrap((GtkButton*)(gobj()->cancel_button));
 
253
}
 
254
 
 
255
const Button* FileSelection::get_cancel_button() const
 
256
{
 
257
  return Glib::wrap((GtkButton*)(gobj()->cancel_button));
 
258
}
 
259
 
 
260
Button* FileSelection::get_help_button()
 
261
{
 
262
  return Glib::wrap((GtkButton*)(gobj()->help_button));
 
263
}
 
264
 
 
265
const Button* FileSelection::get_help_button() const
 
266
{
 
267
  return Glib::wrap((GtkButton*)(gobj()->help_button));
 
268
}
 
269
 
 
270
HButtonBox* FileSelection::get_button_area()
 
271
{
 
272
  return Glib::wrap((GtkHButtonBox*)(gobj()->button_area));
 
273
}
 
274
 
 
275
const HButtonBox* FileSelection::get_button_area() const
 
276
{
 
277
  return Glib::wrap((GtkHButtonBox*)(gobj()->button_area));
 
278
}
 
279
 
 
280
HBox* FileSelection::get_action_area()
 
281
{
 
282
  return Glib::wrap((GtkHBox*)(gobj()->action_area));
 
283
}
 
284
 
 
285
const HBox* FileSelection::get_action_area() const
 
286
{
 
287
  return Glib::wrap((GtkHBox*)(gobj()->action_area));
 
288
}
 
289
 
 
290
 
 
291
Glib::PropertyProxy<bool> FileSelection::property_show_fileops() 
 
292
{
 
293
  return Glib::PropertyProxy<bool>(this, "show-fileops");
 
294
}
 
295
 
 
296
Glib::PropertyProxy_ReadOnly<bool> FileSelection::property_show_fileops() const
 
297
{
 
298
  return Glib::PropertyProxy_ReadOnly<bool>(this, "show-fileops");
 
299
}
 
300
 
 
301
Glib::PropertyProxy<std::string> FileSelection::property_filename() 
 
302
{
 
303
  return Glib::PropertyProxy<std::string>(this, "filename");
 
304
}
 
305
 
 
306
Glib::PropertyProxy_ReadOnly<std::string> FileSelection::property_filename() const
 
307
{
 
308
  return Glib::PropertyProxy_ReadOnly<std::string>(this, "filename");
 
309
}
 
310
 
 
311
Glib::PropertyProxy<bool> FileSelection::property_select_multiple() 
 
312
{
 
313
  return Glib::PropertyProxy<bool>(this, "select-multiple");
 
314
}
 
315
 
 
316
Glib::PropertyProxy_ReadOnly<bool> FileSelection::property_select_multiple() const
 
317
{
 
318
  return Glib::PropertyProxy_ReadOnly<bool>(this, "select-multiple");
 
319
}
 
320
 
 
321
 
 
322
} // namespace Gtk
 
323
 
 
324