~ubuntu-branches/ubuntu/karmic/gtkglextmm/karmic

« back to all changes in this revision

Viewing changes to gdkglext/gdkmm/gl/context.cc

  • Committer: Bazaar Package Importer
  • Author(s): David Morris
  • Date: 2008-02-07 20:19:40 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20080207201940-5dx3bhhd8jlyzodn
Tags: 1.2.0-0ubuntu1
* Upgraded to version 1.2.0
* Restored into Hardy (LP: #190175)
* Changed package name to libgtkglextmm-x11-1.2 to match SONAME
* Removed unrequired packaging files from debian/
* Upgrade debian/copyright to point at GPL2 rather than GPL
* Added Silicon Graphics Inc's copyright on files to debian/copyright
* Added the licence for examples/trackball.c examples/trackball.h to
  debian/copyright

Show diffs side-by-side

added added

removed removed

Lines of Context:
112
112
    // Glib::Class has to know the class init function to clone custom types.
113
113
    class_init_func_ = &Context_Class::class_init_function;
114
114
 
115
 
    // TODO: This is currently just optimized away, apparently with no harm.
116
 
    // Is it actually necessary?
 
115
    // This is actually just optimized away, apparently with no harm.
117
116
    // Make sure that the parent type has been created.
118
 
    CppClassParent::CppObjectType::get_type();
 
117
    //CppClassParent::CppObjectType::get_type();
119
118
 
120
119
    // Create the wrapper type, with the same class/instance size as the base type.
121
120
    register_derived_type(gdk_gl_context_get_type());
161
160
Context::~Context()
162
161
{}
163
162
 
 
163
 
164
164
Context::CppClassType Context::context_class_; // initialize static member
165
165
 
166
166
GType Context::get_type()
179
179
 
180
180
  Glib::RefPtr<Drawable> retvalue = Glib::wrap((GdkGLDrawable*)(gdk_gl_context_get_gl_drawable(gobj())));
181
181
 
182
 
  if(!(retvalue.is_null()))
 
182
  if(retvalue)
183
183
    retvalue->reference(); //The function does not do a ref for us.
184
184
  return retvalue;
185
185
}
189
189
 
190
190
  Glib::RefPtr<const Drawable> retvalue = Glib::wrap((GdkGLDrawable*)(gdk_gl_context_get_gl_drawable(const_cast<GdkGLContext*>(gobj()))));
191
191
 
192
 
  if(!(retvalue.is_null()))
 
192
  if(retvalue)
193
193
    retvalue->reference(); //The function does not do a ref for us.
194
194
  return retvalue;
195
195
}
199
199
 
200
200
  Glib::RefPtr<Config> retvalue = Glib::wrap((GdkGLConfig*)(gdk_gl_context_get_gl_config(gobj())));
201
201
 
202
 
  if(!(retvalue.is_null()))
 
202
  if(retvalue)
203
203
    retvalue->reference(); //The function does not do a ref for us.
204
204
  return retvalue;
205
205
}
209
209
 
210
210
  Glib::RefPtr<const Config> retvalue = Glib::wrap((GdkGLConfig*)(gdk_gl_context_get_gl_config(const_cast<GdkGLContext*>(gobj()))));
211
211
 
212
 
  if(!(retvalue.is_null()))
 
212
  if(retvalue)
213
213
    retvalue->reference(); //The function does not do a ref for us.
214
214
  return retvalue;
215
215
}
219
219
 
220
220
  Glib::RefPtr<Context> retvalue = Glib::wrap((GdkGLContext*)(gdk_gl_context_get_share_list(gobj())));
221
221
 
222
 
  if(!(retvalue.is_null()))
 
222
  if(retvalue)
223
223
    retvalue->reference(); //The function does not do a ref for us.
224
224
  return retvalue;
225
225
}
229
229
 
230
230
  Glib::RefPtr<const Context> retvalue = Glib::wrap((GdkGLContext*)(gdk_gl_context_get_share_list(const_cast<GdkGLContext*>(gobj()))));
231
231
 
232
 
  if(!(retvalue.is_null()))
 
232
  if(retvalue)
233
233
    retvalue->reference(); //The function does not do a ref for us.
234
234
  return retvalue;
235
235
}
249
249
 
250
250
  Glib::RefPtr<Context> retvalue = Glib::wrap((GdkGLContext*)(gdk_gl_context_get_current()));
251
251
 
252
 
  if(!(retvalue.is_null()))
 
252
  if(retvalue)
253
253
    retvalue->reference(); //The function does not do a ref for us.
254
254
  return retvalue;
255
255
}