stub out the Projection classes as well as duplicating the disgusting hack used for...
[moon.git] / src / cbinding.cpp
blob7b1764fece7648c391e488cf16f4104313663c8a
1 /*
2 * Automatically generated, do not edit this file directly
3 */
5 #include <config.h>
7 #include <stdio.h>
8 #include <stdlib.h>
10 #include "cbinding.h"
12 #include "animation.h"
13 #include "application.h"
14 #include "bitmapcache.h"
15 #include "bitmapimage.h"
16 #include "bitmapsource.h"
17 #include "border.h"
18 #include "brush.h"
19 #include "canvas.h"
20 #include "collection.h"
21 #include "contentcontrol.h"
22 #include "control.h"
23 #include "deepzoomimagetilesource.h"
24 #include "dependencyobject.h"
25 #include "dependencyproperty.h"
26 #include "deployment.h"
27 #include "downloader.h"
28 #include "easing.h"
29 #include "effect.h"
30 #include "eventargs.h"
31 #include "frameworkelement.h"
32 #include "geometry.h"
33 #include "glyphs.h"
34 #include "grid.h"
35 #include "imagesource.h"
36 #include "keyboard.h"
37 #include "media.h"
38 #include "mediaelement.h"
39 #include "multiscaleimage.h"
40 #include "multiscalesubimage.h"
41 #include "namescope.h"
42 #include "panel.h"
43 #include "pipeline.h"
44 #include "popup.h"
45 #include "projection.h"
46 #include "resources.h"
47 #include "runtime.h"
48 #include "shape.h"
49 #include "size.h"
50 #include "style.h"
51 #include "stylus.h"
52 #include "tabnavigationwalker.h"
53 #include "template.h"
54 #include "textblock.h"
55 #include "textbox.h"
56 #include "tilesource.h"
57 #include "timeline.h"
58 #include "timemanager.h"
59 #include "transform.h"
60 #include "trigger.h"
61 #include "type.h"
62 #include "uielement.h"
63 #include "uri.h"
64 #include "usercontrol.h"
65 #include "window.h"
66 #include "window-gtk.h"
67 #include "writeablebitmap.h"
68 #include "xaml.h"
69 #include "xap.h"
70 /**
71 * Application
72 **/
73 Application *
74 application_new (void)
76 return new Application ();
80 Application *
81 application_get_current (void)
83 return Application::GetCurrent ();
87 void
88 application_register_callbacks (Application *instance, ApplyDefaultStyleCallback apply_default_style_cb, ApplyStyleCallback apply_style_cb, GetResourceCallback get_resource_cb, ConvertKeyframeValueCallback convert_keyframe_callback)
90 if (instance == NULL)
91 return;
93 instance->RegisterCallbacks (apply_default_style_cb, apply_style_cb, get_resource_cb, convert_keyframe_callback);
97 void
98 application_set_current (Application *current)
100 Application::SetCurrent (current);
105 * ArcSegment
107 ArcSegment *
108 arc_segment_new (void)
110 return new ArcSegment ();
115 * AssemblyPart
117 AssemblyPart *
118 assembly_part_new (void)
120 return new AssemblyPart ();
125 * AssemblyPartCollection
127 AssemblyPartCollection *
128 assembly_part_collection_new (void)
130 return new AssemblyPartCollection ();
135 * AudioStream
137 AudioStream *
138 audio_stream_new (Media *media, int codec_id, int bits_per_sample, int block_align, int sample_rate, int channels, int bit_rate, gpointer extra_data, guint32 extra_data_size)
140 return new AudioStream (media, codec_id, bits_per_sample, block_align, sample_rate, channels, bit_rate, extra_data, extra_data_size);
145 audio_stream_get_bit_rate (AudioStream *instance)
147 if (instance == NULL)
148 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
149 return (int) 0;
151 return instance->GetBitRate ();
156 audio_stream_get_bits_per_sample (AudioStream *instance)
158 if (instance == NULL)
159 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
160 return (int) 0;
162 return instance->GetBitsPerSample ();
167 audio_stream_get_block_align (AudioStream *instance)
169 if (instance == NULL)
170 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
171 return (int) 0;
173 return instance->GetBlockAlign ();
178 audio_stream_get_channels (AudioStream *instance)
180 if (instance == NULL)
181 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
182 return (int) 0;
184 return instance->GetChannels ();
189 audio_stream_get_input_bit_rate (AudioStream *instance)
191 if (instance == NULL)
192 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
193 return (int) 0;
195 return instance->GetInputBitRate ();
200 audio_stream_get_input_bits_per_sample (AudioStream *instance)
202 if (instance == NULL)
203 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
204 return (int) 0;
206 return instance->GetInputBitsPerSample ();
211 audio_stream_get_input_block_align (AudioStream *instance)
213 if (instance == NULL)
214 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
215 return (int) 0;
217 return instance->GetInputBlockAlign ();
222 audio_stream_get_input_channels (AudioStream *instance)
224 if (instance == NULL)
225 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
226 return (int) 0;
228 return instance->GetInputChannels ();
233 audio_stream_get_input_sample_rate (AudioStream *instance)
235 if (instance == NULL)
236 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
237 return (int) 0;
239 return instance->GetInputSampleRate ();
244 audio_stream_get_output_bit_rate (AudioStream *instance)
246 if (instance == NULL)
247 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
248 return (int) 0;
250 return instance->GetOutputBitRate ();
255 audio_stream_get_output_bits_per_sample (AudioStream *instance)
257 if (instance == NULL)
258 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
259 return (int) 0;
261 return instance->GetOutputBitsPerSample ();
266 audio_stream_get_output_block_align (AudioStream *instance)
268 if (instance == NULL)
269 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
270 return (int) 0;
272 return instance->GetOutputBlockAlign ();
277 audio_stream_get_output_channels (AudioStream *instance)
279 if (instance == NULL)
280 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
281 return (int) 0;
283 return instance->GetOutputChannels ();
288 audio_stream_get_output_sample_rate (AudioStream *instance)
290 if (instance == NULL)
291 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
292 return (int) 0;
294 return instance->GetOutputSampleRate ();
299 audio_stream_get_sample_rate (AudioStream *instance)
301 if (instance == NULL)
302 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
303 return (int) 0;
305 return instance->GetSampleRate ();
309 void
310 audio_stream_set_bit_rate (AudioStream *instance, int value)
312 if (instance == NULL)
313 return;
315 instance->SetBitRate (value);
319 void
320 audio_stream_set_bits_per_sample (AudioStream *instance, int value)
322 if (instance == NULL)
323 return;
325 instance->SetBitsPerSample (value);
329 void
330 audio_stream_set_block_align (AudioStream *instance, int value)
332 if (instance == NULL)
333 return;
335 instance->SetBlockAlign (value);
339 void
340 audio_stream_set_channels (AudioStream *instance, int value)
342 if (instance == NULL)
343 return;
345 instance->SetChannels (value);
349 void
350 audio_stream_set_input_bit_rate (AudioStream *instance, int value)
352 if (instance == NULL)
353 return;
355 instance->SetInputBitRate (value);
359 void
360 audio_stream_set_input_bits_per_sample (AudioStream *instance, int value)
362 if (instance == NULL)
363 return;
365 instance->SetInputBitsPerSample (value);
369 void
370 audio_stream_set_input_block_align (AudioStream *instance, int value)
372 if (instance == NULL)
373 return;
375 instance->SetInputBlockAlign (value);
379 void
380 audio_stream_set_input_channels (AudioStream *instance, int value)
382 if (instance == NULL)
383 return;
385 instance->SetInputChannels (value);
389 void
390 audio_stream_set_input_sample_rate (AudioStream *instance, int value)
392 if (instance == NULL)
393 return;
395 instance->SetInputSampleRate (value);
399 void
400 audio_stream_set_output_bit_rate (AudioStream *instance, int value)
402 if (instance == NULL)
403 return;
405 instance->SetOutputBitRate (value);
409 void
410 audio_stream_set_output_bits_per_sample (AudioStream *instance, int value)
412 if (instance == NULL)
413 return;
415 instance->SetOutputBitsPerSample (value);
419 void
420 audio_stream_set_output_block_align (AudioStream *instance, int value)
422 if (instance == NULL)
423 return;
425 instance->SetOutputBlockAlign (value);
429 void
430 audio_stream_set_output_channels (AudioStream *instance, int value)
432 if (instance == NULL)
433 return;
435 instance->SetOutputChannels (value);
439 void
440 audio_stream_set_output_sample_rate (AudioStream *instance, int value)
442 if (instance == NULL)
443 return;
445 instance->SetOutputSampleRate (value);
449 void
450 audio_stream_set_sample_rate (AudioStream *instance, int value)
452 if (instance == NULL)
453 return;
455 instance->SetSampleRate (value);
460 * BackEase
462 BackEase *
463 back_ease_new (void)
465 return new BackEase ();
469 double
470 back_ease_ease_in_core (BackEase *instance, double normalizedTime)
472 if (instance == NULL)
473 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
474 return (double) 0;
476 return instance->EaseInCore (normalizedTime);
481 * BeginStoryboard
483 BeginStoryboard *
484 begin_storyboard_new (void)
486 return new BeginStoryboard ();
491 * BezierSegment
493 BezierSegment *
494 bezier_segment_new (void)
496 return new BezierSegment ();
501 * BitmapCache
503 BitmapCache *
504 bitmap_cache_new (void)
506 return new BitmapCache ();
511 * BitmapImage
513 BitmapImage *
514 bitmap_image_new (void)
516 return new BitmapImage ();
520 void
521 bitmap_image_pixbuf_write (BitmapImage *instance, gpointer buffer, gint32 offset, gint32 n)
523 if (instance == NULL)
524 return;
526 instance->PixbufWrite (buffer, offset, n);
530 void
531 bitmap_image_pixmap_complete (BitmapImage *instance)
533 if (instance == NULL)
534 return;
536 instance->PixmapComplete ();
541 * BitmapSource
543 BitmapSource *
544 bitmap_source_new (void)
546 return new BitmapSource ();
550 gpointer
551 bitmap_source_get_bitmap_data (BitmapSource *instance)
553 if (instance == NULL)
554 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
555 return (gpointer) 0;
557 return instance->GetBitmapData ();
561 void
562 bitmap_source_invalidate (BitmapSource *instance)
564 if (instance == NULL)
565 return;
567 instance->Invalidate ();
571 void
572 bitmap_source_set_bitmap_data (BitmapSource *instance, gpointer data, bool own)
574 if (instance == NULL)
575 return;
577 instance->SetBitmapData (data, own);
582 * BlurEffect
584 BlurEffect *
585 blur_effect_new (void)
587 return new BlurEffect ();
592 * Border
594 Border *
595 border_new (void)
597 return new Border ();
602 * BounceEase
604 BounceEase *
605 bounce_ease_new (void)
607 return new BounceEase ();
611 double
612 bounce_ease_ease_in_core (BounceEase *instance, double normalizedTime)
614 if (instance == NULL)
615 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
616 return (double) 0;
618 return instance->EaseInCore (normalizedTime);
623 * Brush
625 Brush *
626 brush_new (void)
628 return new Brush ();
633 * CacheMode
635 CacheMode *
636 cache_mode_new (void)
638 return new CacheMode ();
643 * Canvas
645 Canvas *
646 canvas_new (void)
648 return new Canvas ();
653 * CircleEase
655 CircleEase *
656 circle_ease_new (void)
658 return new CircleEase ();
662 double
663 circle_ease_ease_in_core (CircleEase *instance, double normalizedTime)
665 if (instance == NULL)
666 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
667 return (double) 0;
669 return instance->EaseInCore (normalizedTime);
674 * Collection
677 collection_add_with_error (Collection *instance, Value *value, MoonError *error)
679 if (instance == NULL)
680 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
681 return (int) 0;
683 if (error == NULL)
684 g_warning ("Moonlight: Called collection_add_with_error () with error == NULL.");
685 return instance->AddWithError (value, error);
689 bool
690 collection_clear (Collection *instance)
692 if (instance == NULL)
693 return false;
695 return instance->Clear ();
699 bool
700 collection_contains (Collection *instance, Value *value)
702 if (instance == NULL)
703 return false;
705 return instance->Contains (value);
710 collection_get_count (Collection *instance)
712 if (instance == NULL)
713 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
714 return (int) 0;
716 return instance->GetCount ();
721 collection_get_element_type (Collection *instance)
723 if (instance == NULL)
724 return Type::INVALID;
726 return instance->GetElementType ();
730 CollectionIterator *
731 collection_get_iterator (Collection *instance)
733 if (instance == NULL)
734 return NULL;
736 return instance->GetIterator ();
740 Value *
741 collection_get_value_at_with_error (Collection *instance, int index, MoonError *error)
743 if (instance == NULL)
744 return NULL;
746 if (error == NULL)
747 g_warning ("Moonlight: Called collection_get_value_at_with_error () with error == NULL.");
748 return instance->GetValueAtWithError (index, error);
753 collection_index_of (Collection *instance, Value *value)
755 if (instance == NULL)
756 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
757 return (int) 0;
759 return instance->IndexOf (value);
763 bool
764 collection_insert_with_error (Collection *instance, int index, Value *value, MoonError *error)
766 if (instance == NULL)
767 return false;
769 if (error == NULL)
770 g_warning ("Moonlight: Called collection_insert_with_error () with error == NULL.");
771 return instance->InsertWithError (index, value, error);
775 bool
776 collection_remove (Collection *instance, Value *value)
778 if (instance == NULL)
779 return false;
781 return instance->Remove (value);
785 bool
786 collection_remove_at_with_error (Collection *instance, int index, MoonError *error)
788 if (instance == NULL)
789 return false;
791 if (error == NULL)
792 g_warning ("Moonlight: Called collection_remove_at_with_error () with error == NULL.");
793 return instance->RemoveAtWithError (index, error);
797 bool
798 collection_set_value_at_with_error (Collection *instance, int index, Value *value, MoonError *error)
800 if (instance == NULL)
801 return false;
803 if (error == NULL)
804 g_warning ("Moonlight: Called collection_set_value_at_with_error () with error == NULL.");
805 return instance->SetValueAtWithError (index, value, error);
810 * CollectionChangedEventArgs
812 CollectionChangedEventArgs *
813 collection_changed_event_args_new (void)
815 return new CollectionChangedEventArgs ();
820 collection_changed_event_args_get_changed_action (CollectionChangedEventArgs *instance)
822 if (instance == NULL)
823 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
824 return (CollectionChangedAction) 0;
826 return instance->GetChangedAction ();
831 collection_changed_event_args_get_index (CollectionChangedEventArgs *instance)
833 if (instance == NULL)
834 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
835 return (int) 0;
837 return instance->GetIndex ();
841 Value *
842 collection_changed_event_args_get_new_item (CollectionChangedEventArgs *instance)
844 if (instance == NULL)
845 return NULL;
847 return instance->GetNewItem ();
851 Value *
852 collection_changed_event_args_get_old_item (CollectionChangedEventArgs *instance)
854 if (instance == NULL)
855 return NULL;
857 return instance->GetOldItem ();
861 void
862 collection_changed_event_args_set_changed_action (CollectionChangedEventArgs *instance, int action)
864 if (instance == NULL)
865 return;
867 instance->SetChangedAction ((CollectionChangedAction) action);
871 void
872 collection_changed_event_args_set_index (CollectionChangedEventArgs *instance, int index)
874 if (instance == NULL)
875 return;
877 instance->SetIndex (index);
881 void
882 collection_changed_event_args_set_new_item (CollectionChangedEventArgs *instance, Value *item)
884 if (instance == NULL)
885 return;
887 instance->SetNewItem (item);
891 void
892 collection_changed_event_args_set_old_item (CollectionChangedEventArgs *instance, Value *item)
894 if (instance == NULL)
895 return;
897 instance->SetOldItem (item);
902 * CollectionIterator
904 void
905 collection_iterator_destroy (CollectionIterator *iterator)
907 CollectionIterator::Destroy (iterator);
911 Value *
912 collection_iterator_get_current (CollectionIterator *instance, int *error)
914 if (instance == NULL)
915 return NULL;
917 return instance->GetCurrent (error);
922 collection_iterator_next (CollectionIterator *instance)
924 if (instance == NULL)
925 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
926 return (int) 0;
928 return instance->Next ();
932 bool
933 collection_iterator_reset (CollectionIterator *instance)
935 if (instance == NULL)
936 return false;
938 return instance->Reset ();
943 * ColorAnimation
945 ColorAnimation *
946 color_animation_new (void)
948 return new ColorAnimation ();
953 * ColorAnimationUsingKeyFrames
955 ColorAnimationUsingKeyFrames *
956 color_animation_using_key_frames_new (void)
958 return new ColorAnimationUsingKeyFrames ();
963 * ColorKeyFrame
965 ColorKeyFrame *
966 color_key_frame_new (void)
968 return new ColorKeyFrame ();
973 * ColorKeyFrameCollection
975 ColorKeyFrameCollection *
976 color_key_frame_collection_new (void)
978 return new ColorKeyFrameCollection ();
983 * ColumnDefinition
985 ColumnDefinition *
986 column_definition_new (void)
988 return new ColumnDefinition ();
993 * ColumnDefinitionCollection
995 ColumnDefinitionCollection *
996 column_definition_collection_new (void)
998 return new ColumnDefinitionCollection ();
1003 * ContentChangedEventArgs
1005 Value *
1006 content_changed_event_args_get_new_content (ContentChangedEventArgs *instance)
1008 if (instance == NULL)
1009 return NULL;
1011 return instance->GetNewContent ();
1015 Value *
1016 content_changed_event_args_get_old_content (ContentChangedEventArgs *instance)
1018 if (instance == NULL)
1019 return NULL;
1021 return instance->GetOldContent ();
1026 * ContentControl
1028 ContentControl *
1029 content_control_new (void)
1031 return new ContentControl ();
1035 bool
1036 content_control_get_content_sets_parent (ContentControl *instance)
1038 if (instance == NULL)
1039 return false;
1041 return instance->GetContentSetsParent ();
1045 void
1046 content_control_set_content_sets_parent (ContentControl *instance, bool value)
1048 if (instance == NULL)
1049 return;
1051 instance->SetContentSetsParent (value);
1056 * Control
1058 Control *
1059 control_new (void)
1061 return new Control ();
1065 DependencyObject *
1066 control_get_template_child (Control *instance, const char *name)
1068 if (instance == NULL)
1069 return NULL;
1071 return instance->GetTemplateChild (name);
1076 * ControlTemplate
1078 ControlTemplate *
1079 control_template_new (void)
1081 return new ControlTemplate ();
1086 * CubicEase
1088 CubicEase *
1089 cubic_ease_new (void)
1091 return new CubicEase ();
1095 double
1096 cubic_ease_ease_in_core (CubicEase *instance, double normalizedTime)
1098 if (instance == NULL)
1099 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1100 return (double) 0;
1102 return instance->EaseInCore (normalizedTime);
1107 * CursorPositionChangedEventArgs
1109 CursorPositionChangedEventArgs *
1110 cursor_position_changed_event_args_new (void)
1112 return new CursorPositionChangedEventArgs ();
1116 double
1117 cursor_position_changed_event_args_get_cursor_height (CursorPositionChangedEventArgs *instance)
1119 if (instance == NULL)
1120 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1121 return (double) 0;
1123 return instance->GetCursorHeight ();
1127 double
1128 cursor_position_changed_event_args_get_cursor_x (CursorPositionChangedEventArgs *instance)
1130 if (instance == NULL)
1131 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1132 return (double) 0;
1134 return instance->GetCursorX ();
1138 double
1139 cursor_position_changed_event_args_get_cursor_y (CursorPositionChangedEventArgs *instance)
1141 if (instance == NULL)
1142 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1143 return (double) 0;
1145 return instance->GetCursorY ();
1150 * DataTemplate
1152 DataTemplate *
1153 data_template_new (void)
1155 return new DataTemplate ();
1160 * DeepZoomImageTileSource
1162 DeepZoomImageTileSource *
1163 deep_zoom_image_tile_source_new (void)
1165 return new DeepZoomImageTileSource ();
1170 * DependencyObject
1172 void
1173 dependency_object_add_property_change_handler (DependencyObject *instance, DependencyProperty *property, PropertyChangeHandler cb, gpointer closure)
1175 if (instance == NULL)
1176 return;
1178 instance->AddPropertyChangeHandler (property, cb, closure);
1182 void
1183 dependency_object_clear_value (DependencyObject *instance, DependencyProperty *property, bool notify_listeners, MoonError *error)
1185 if (instance == NULL)
1186 return;
1188 if (error == NULL)
1189 g_warning ("Moonlight: Called dependency_object_clear_value () with error == NULL.");
1190 instance->ClearValue (property, notify_listeners, error);
1194 DependencyObject *
1195 dependency_object_new (void)
1197 return new DependencyObject ();
1201 DependencyObject *
1202 dependency_object_find_name (DependencyObject *instance, const char *name, int *element_kind)
1204 if (instance == NULL)
1205 return NULL;
1207 return instance->FindName (name, (Type::Kind*) element_kind);
1211 const char *
1212 dependency_object_get_name (DependencyObject *instance)
1214 if (instance == NULL)
1215 return NULL;
1217 return instance->GetName ();
1221 DependencyObject *
1222 dependency_object_get_template_owner (DependencyObject *instance)
1224 if (instance == NULL)
1225 return NULL;
1227 return instance->GetTemplateOwner ();
1231 Value *
1232 dependency_object_get_value_no_default_with_error (DependencyObject *instance, DependencyProperty *property, MoonError *error)
1234 if (instance == NULL)
1235 return NULL;
1237 if (error == NULL)
1238 g_warning ("Moonlight: Called dependency_object_get_value_no_default_with_error () with error == NULL.");
1239 return instance->GetValueNoDefaultWithError (property, error);
1243 Value *
1244 dependency_object_get_value_with_error (DependencyObject *instance, int whatami, DependencyProperty *property, MoonError *error)
1246 if (instance == NULL)
1247 return NULL;
1249 if (error == NULL)
1250 g_warning ("Moonlight: Called dependency_object_get_value_with_error () with error == NULL.");
1251 return instance->GetValueWithError ((Type::Kind) whatami, property, error);
1255 Value *
1256 dependency_object_read_local_value_with_error (DependencyObject *instance, DependencyProperty *property, MoonError *error)
1258 if (instance == NULL)
1259 return NULL;
1261 if (error == NULL)
1262 g_warning ("Moonlight: Called dependency_object_read_local_value_with_error () with error == NULL.");
1263 return instance->ReadLocalValueWithError (property, error);
1267 void
1268 dependency_object_remove_property_change_handler (DependencyObject *instance, DependencyProperty *property, PropertyChangeHandler cb)
1270 if (instance == NULL)
1271 return;
1273 instance->RemovePropertyChangeHandler (property, cb);
1277 void
1278 dependency_object_set_name (DependencyObject *instance, const char *name)
1280 if (instance == NULL)
1281 return;
1283 instance->SetName (name);
1287 void
1288 dependency_object_set_parent_safe (DependencyObject *instance, DependencyObject *parent, MoonError *error)
1290 if (instance == NULL)
1291 return;
1293 if (error == NULL)
1294 g_warning ("Moonlight: Called dependency_object_set_parent_safe () with error == NULL.");
1295 instance->SetParentSafe (parent, error);
1299 void
1300 dependency_object_set_template_owner (DependencyObject *instance, DependencyObject *value)
1302 if (instance == NULL)
1303 return;
1305 instance->SetTemplateOwner (value);
1309 bool
1310 dependency_object_set_value_with_error (DependencyObject *instance, DependencyProperty *property, Value *value, MoonError *error)
1312 if (instance == NULL)
1313 return false;
1315 if (error == NULL)
1316 g_warning ("Moonlight: Called dependency_object_set_value_with_error () with error == NULL.");
1317 return instance->SetValueWithError (property, value, error);
1322 * DependencyObjectCollection
1324 DependencyObjectCollection *
1325 dependency_object_collection_new (void)
1327 return new DependencyObjectCollection ();
1332 * DependencyProperty
1334 Value *
1335 dependency_property_get_default_value (DependencyProperty *instance)
1337 if (instance == NULL)
1338 return NULL;
1340 return instance->GetDefaultValue ();
1344 DependencyProperty *
1345 dependency_property_get_dependency_property (int type, const char *name)
1347 return DependencyProperty::GetDependencyProperty ((Type::Kind) type, name);
1351 DependencyProperty *
1352 dependency_property_get_dependency_property_full (int type, const char *name, bool inherits)
1354 return DependencyProperty::GetDependencyPropertyFull ((Type::Kind) type, name, inherits);
1358 const char *
1359 dependency_property_get_name (DependencyProperty *instance)
1361 if (instance == NULL)
1362 return NULL;
1364 return instance->GetName ();
1369 dependency_property_get_property_type (DependencyProperty *instance)
1371 if (instance == NULL)
1372 return Type::INVALID;
1374 return instance->GetPropertyType ();
1378 bool
1379 dependency_property_is_attached (DependencyProperty *instance)
1381 if (instance == NULL)
1382 return false;
1384 return instance->IsAttached ();
1388 bool
1389 dependency_property_is_nullable (DependencyProperty *instance)
1391 if (instance == NULL)
1392 return false;
1394 return instance->IsNullable ();
1398 bool
1399 dependency_property_is_read_only (DependencyProperty *instance)
1401 if (instance == NULL)
1402 return false;
1404 return instance->IsReadOnly ();
1408 DependencyProperty *
1409 dependency_property_register_core_property (const char *name, int property_type, int owner_type, Value *defaultValue, bool attached, bool read_only, PropertyChangeHandler callback)
1411 return DependencyProperty::RegisterCoreProperty (name, (Type::Kind) property_type, (Type::Kind) owner_type, defaultValue, attached, read_only, callback);
1415 DependencyProperty *
1416 dependency_property_register_custom_property (const char *name, int property_type, int owner_type, Value *defaultValue, bool attached, bool read_only, PropertyChangeHandler callback)
1418 return DependencyProperty::RegisterCustomProperty (name, (Type::Kind) property_type, (Type::Kind) owner_type, defaultValue, attached, read_only, callback);
1422 void
1423 dependency_property_set_is_nullable (DependencyProperty *instance, bool value)
1425 if (instance == NULL)
1426 return;
1428 instance->SetIsNullable (value);
1432 void
1433 dependency_property_set_property_changed_callback (DependencyProperty *instance, PropertyChangeHandler changed_callback)
1435 if (instance == NULL)
1436 return;
1438 instance->SetPropertyChangedCallback (changed_callback);
1443 * Deployment
1445 Deployment *
1446 deployment_new (void)
1448 return new Deployment ();
1452 Deployment *
1453 deployment_get_current (void)
1455 return Deployment::GetCurrent ();
1459 Surface *
1460 deployment_get_surface_reffed (Deployment *instance)
1462 if (instance == NULL)
1463 return NULL;
1465 return instance->GetSurfaceReffed ();
1469 Types *
1470 deployment_get_types (Deployment *instance)
1472 if (instance == NULL)
1473 return NULL;
1475 return instance->GetTypes ();
1479 void
1480 deployment_set_current (Deployment *value)
1482 Deployment::SetCurrent (value);
1486 void
1487 deployment_set_current_application (Deployment *instance, Application *value)
1489 if (instance == NULL)
1490 return;
1492 instance->SetCurrentApplication (value);
1496 void
1497 deployment_set_is_loaded_from_xap (Deployment *instance, bool flag)
1499 if (instance == NULL)
1500 return;
1502 instance->SetIsLoadedFromXap (flag);
1507 * DiscreteColorKeyFrame
1509 DiscreteColorKeyFrame *
1510 discrete_color_key_frame_new (void)
1512 return new DiscreteColorKeyFrame ();
1517 * DiscreteDoubleKeyFrame
1519 DiscreteDoubleKeyFrame *
1520 discrete_double_key_frame_new (void)
1522 return new DiscreteDoubleKeyFrame ();
1527 * DiscreteObjectKeyFrame
1529 DiscreteObjectKeyFrame *
1530 discrete_object_key_frame_new (void)
1532 return new DiscreteObjectKeyFrame ();
1537 * DiscretePointKeyFrame
1539 DiscretePointKeyFrame *
1540 discrete_point_key_frame_new (void)
1542 return new DiscretePointKeyFrame ();
1547 * DispatcherTimer
1549 DispatcherTimer *
1550 dispatcher_timer_new (void)
1552 return new DispatcherTimer ();
1556 void
1557 dispatcher_timer_start (DispatcherTimer *instance)
1559 if (instance == NULL)
1560 return;
1562 instance->Start ();
1566 void
1567 dispatcher_timer_stop (DispatcherTimer *instance)
1569 if (instance == NULL)
1570 return;
1572 instance->Stop ();
1577 * DoubleAnimation
1579 DoubleAnimation *
1580 double_animation_new (void)
1582 return new DoubleAnimation ();
1587 * DoubleAnimationUsingKeyFrames
1589 DoubleAnimationUsingKeyFrames *
1590 double_animation_using_key_frames_new (void)
1592 return new DoubleAnimationUsingKeyFrames ();
1597 * DoubleCollection
1599 DoubleCollection *
1600 double_collection_new (void)
1602 return new DoubleCollection ();
1607 * DoubleKeyFrame
1609 DoubleKeyFrame *
1610 double_key_frame_new (void)
1612 return new DoubleKeyFrame ();
1617 * DoubleKeyFrameCollection
1619 DoubleKeyFrameCollection *
1620 double_key_frame_collection_new (void)
1622 return new DoubleKeyFrameCollection ();
1627 * Downloader
1629 void *
1630 downloader_create_web_request (Downloader *instance, const char *method, const char *uri)
1632 if (instance == NULL)
1633 return NULL;
1635 return instance->CreateWebRequest (method, uri);
1639 Downloader *
1640 downloader_new (void)
1642 return new Downloader ();
1646 void
1647 downloader_notify_failed (Downloader *instance, const char *msg)
1649 if (instance == NULL)
1650 return;
1652 instance->NotifyFailed (msg);
1656 void
1657 downloader_notify_finished (Downloader *instance, const char *final_uri)
1659 if (instance == NULL)
1660 return;
1662 instance->NotifyFinished (final_uri);
1666 void
1667 downloader_notify_size (Downloader *instance, gint64 size)
1669 if (instance == NULL)
1670 return;
1672 instance->NotifySize (size);
1676 void
1677 downloader_set_functions (DownloaderCreateStateFunc create_state, DownloaderDestroyStateFunc destroy_state, DownloaderOpenFunc open, DownloaderSendFunc send, DownloaderAbortFunc abort, DownloaderHeaderFunc header, DownloaderBodyFunc body, DownloaderCreateWebRequestFunc request, DownloaderSetResponseHeaderCallbackFunc response_header_callback, DownloaderGetResponseFunc get_response)
1679 Downloader::SetFunctions (create_state, destroy_state, open, send, abort, header, body, request, response_header_callback, get_response);
1683 void
1684 downloader_write (Downloader *instance, void *buf, gint32 offset, gint32 n)
1686 if (instance == NULL)
1687 return;
1689 instance->Write (buf, offset, n);
1694 * DownloaderRequest
1696 void
1697 downloader_request_free (DownloaderRequest *instance)
1699 delete instance;
1703 void
1704 downloader_request_abort (DownloaderRequest *instance)
1706 if (instance == NULL)
1707 return;
1709 instance->Abort ();
1713 DownloaderResponse *
1714 downloader_request_get_downloader_response (DownloaderRequest *instance)
1716 if (instance == NULL)
1717 return NULL;
1719 return instance->GetDownloaderResponse ();
1723 bool
1724 downloader_request_get_response (DownloaderRequest *instance, DownloaderResponseStartedHandler started, DownloaderResponseDataAvailableHandler available, DownloaderResponseFinishedHandler finished, gpointer context)
1726 if (instance == NULL)
1727 return false;
1729 return instance->GetResponse (started, available, finished, context);
1733 const bool
1734 downloader_request_is_aborted (DownloaderRequest *instance)
1736 if (instance == NULL)
1737 return false;
1739 return instance->IsAborted ();
1743 void
1744 downloader_request_set_body (DownloaderRequest *instance, void *body, int size)
1746 if (instance == NULL)
1747 return;
1749 instance->SetBody (body, size);
1753 void
1754 downloader_request_set_http_header (DownloaderRequest *instance, const char *name, const char *value)
1756 if (instance == NULL)
1757 return;
1759 instance->SetHttpHeader (name, value);
1764 * DownloaderResponse
1766 void
1767 downloader_response_free (DownloaderResponse *instance)
1769 delete instance;
1773 void
1774 downloader_response_abort (DownloaderResponse *instance)
1776 if (instance == NULL)
1777 return;
1779 instance->Abort ();
1784 downloader_response_get_response_status (DownloaderResponse *instance)
1786 if (instance == NULL)
1787 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1788 return (int) 0;
1790 return instance->GetResponseStatus ();
1794 const char *
1795 downloader_response_get_response_status_text (DownloaderResponse *instance)
1797 if (instance == NULL)
1798 return NULL;
1800 return instance->GetResponseStatusText ();
1804 void
1805 downloader_response_set_header_visitor (DownloaderResponse *instance, DownloaderResponseHeaderCallback visitor, gpointer context)
1807 if (instance == NULL)
1808 return;
1810 instance->SetHeaderVisitor (visitor, context);
1815 * DownloadProgressEventArgs
1817 double
1818 download_progress_event_args_get_progress (DownloadProgressEventArgs *instance)
1820 if (instance == NULL)
1821 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1822 return (double) 0;
1824 return instance->GetProgress ();
1829 * DrawingAttributes
1831 DrawingAttributes *
1832 drawing_attributes_new (void)
1834 return new DrawingAttributes ();
1839 * DropShadowEffect
1841 DropShadowEffect *
1842 drop_shadow_effect_new (void)
1844 return new DropShadowEffect ();
1849 * EasingColorKeyFrame
1851 EasingColorKeyFrame *
1852 easing_color_key_frame_new (void)
1854 return new EasingColorKeyFrame ();
1859 * EasingDoubleKeyFrame
1861 EasingDoubleKeyFrame *
1862 easing_double_key_frame_new (void)
1864 return new EasingDoubleKeyFrame ();
1869 * EasingFunctionBase
1871 EasingFunctionBase *
1872 easing_function_base_new (void)
1874 return new EasingFunctionBase ();
1878 void
1879 easing_function_base_set_easing_function (EasingFunctionBase *instance, EasingFunction value)
1881 if (instance == NULL)
1882 return;
1884 instance->SetEasingFunction (value);
1889 * EasingPointKeyFrame
1891 EasingPointKeyFrame *
1892 easing_point_key_frame_new (void)
1894 return new EasingPointKeyFrame ();
1899 * Effect
1901 Effect *
1902 effect_new (void)
1904 return new Effect ();
1909 * ElasticEase
1911 double
1912 elastic_ease_ease_in_core (ElasticEase *instance, double normalizedTime)
1914 if (instance == NULL)
1915 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1916 return (double) 0;
1918 return instance->EaseInCore (normalizedTime);
1922 ElasticEase *
1923 elastic_ease_new (void)
1925 return new ElasticEase ();
1930 * Ellipse
1932 Ellipse *
1933 ellipse_new (void)
1935 return new Ellipse ();
1940 * EllipseGeometry
1942 EllipseGeometry *
1943 ellipse_geometry_new (void)
1945 return new EllipseGeometry ();
1950 * ErrorEventArgs
1953 error_event_args_get_error_code (ErrorEventArgs *instance)
1955 if (instance == NULL)
1956 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1957 return (int) 0;
1959 return instance->GetErrorCode ();
1963 const char *
1964 error_event_args_get_error_message (ErrorEventArgs *instance)
1966 if (instance == NULL)
1967 return NULL;
1969 return instance->GetErrorMessage ();
1974 error_event_args_get_error_type (ErrorEventArgs *instance)
1976 if (instance == NULL)
1977 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1978 return (int) 0;
1980 return instance->GetErrorType ();
1984 gpointer
1985 error_event_args_get_moon_error (ErrorEventArgs *instance)
1987 if (instance == NULL)
1988 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
1989 return (gpointer) 0;
1991 return instance->GetMoonError ();
1996 * EventObject
1999 event_object_add_handler (EventObject *instance, int event_id, EventHandler handler, gpointer data, GDestroyNotify data_dtor)
2001 if (instance == NULL)
2002 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2003 return (int) 0;
2005 return instance->AddHandler (event_id, handler, data, data_dtor);
2009 void
2010 event_object_add_on_event_handler (EventObject *instance, int event_id, EventHandler handler, gpointer data, GDestroyNotify data_dtor)
2012 if (instance == NULL)
2013 return;
2015 instance->AddOnEventHandler (event_id, handler, data, data_dtor);
2019 void
2020 event_object_add_toggle_ref_notifier (EventObject *instance, ToggleNotifyHandler tr)
2022 if (instance == NULL)
2023 return;
2025 instance->AddToggleRefNotifier (tr);
2030 event_object_add_xaml_handler (EventObject *instance, int event_id, EventHandler handler, gpointer data, GDestroyNotify data_dtor)
2032 if (instance == NULL)
2033 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2034 return (int) 0;
2036 return instance->AddXamlHandler (event_id, handler, data, data_dtor);
2040 void
2041 event_object_do_emit_current_context (EventObject *instance, int event_id, EventArgs *calldata)
2043 if (instance == NULL)
2044 return;
2046 instance->DoEmitCurrentContext (event_id, calldata);
2051 event_object_get_object_type (EventObject *instance)
2053 if (instance == NULL)
2054 return Type::INVALID;
2056 return instance->GetObjectType ();
2060 const char *
2061 event_object_get_type_name (EventObject *instance)
2063 if (instance == NULL)
2064 return NULL;
2066 return instance->GetTypeName ();
2070 void
2071 event_object_ref (EventObject *instance)
2073 if (instance == NULL)
2074 return;
2076 instance->ref ();
2081 event_object_remove_handler (EventObject *instance, int event_id, EventHandler handler, gpointer data)
2083 if (instance == NULL)
2084 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2085 return (int) 0;
2087 return instance->RemoveHandler (event_id, handler, data);
2091 void
2092 event_object_remove_on_event_handler (EventObject *instance, int event_id, EventHandler handler, gpointer data)
2094 if (instance == NULL)
2095 return;
2097 instance->RemoveOnEventHandler (event_id, handler, data);
2101 void
2102 event_object_remove_toggle_ref_notifier (EventObject *instance)
2104 if (instance == NULL)
2105 return;
2107 instance->RemoveToggleRefNotifier ();
2111 void
2112 event_object_set_object_type (EventObject *instance, int value)
2114 if (instance == NULL)
2115 return;
2117 instance->SetObjectType ((Type::Kind) value);
2121 void
2122 event_object_unref (EventObject *instance)
2124 if (instance == NULL)
2125 return;
2127 instance->unref ();
2132 * EventTrigger
2134 EventTrigger *
2135 event_trigger_new (void)
2137 return new EventTrigger ();
2142 * ExponentialEase
2144 double
2145 exponential_ease_ease_in_core (ExponentialEase *instance, double normalizedTime)
2147 if (instance == NULL)
2148 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2149 return (double) 0;
2151 return instance->EaseInCore (normalizedTime);
2155 ExponentialEase *
2156 exponential_ease_new (void)
2158 return new ExponentialEase ();
2163 * ExtensionPart
2165 ExtensionPart *
2166 extension_part_new (void)
2168 return new ExtensionPart ();
2173 * ExternalDecoder
2175 ExternalDecoder *
2176 external_decoder_new (Media *media, IMediaStream *stream, void *instance, const char *name, ExternalDecoder_DecodeFrameAsyncCallback decode_frame_async, ExternalDecoder_OpenDecoderAsyncCallback open_decoder_async, ExternalDecoder_CleanupCallback cleanup, ExternalDecoder_CleanStateCallback clean_state, ExternalDecoder_HasDelayedFrameCallback has_delayed_frame, ExternalDecoder_DisposeCallback dispose, ExternalDecoder_DtorCallback dtor)
2178 return new ExternalDecoder (media, stream, instance, name, decode_frame_async, open_decoder_async, cleanup, clean_state, has_delayed_frame, dispose, dtor);
2183 * ExternalDecoderInfo
2185 ExternalDecoderInfo *
2186 external_decoder_info_new (void *instance, const char *name, ExternalDecoderInfo_SupportsCallback supports, ExternalDecoderInfo_Create create, ExternalDecoderInfo_dtor dtor)
2188 return new ExternalDecoderInfo (instance, name, supports, create, dtor);
2193 * ExternalDemuxer
2195 gint32
2196 external_demuxer_add_stream (ExternalDemuxer *instance, IMediaStream *stream)
2198 if (instance == NULL)
2199 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2200 return (gint32) 0;
2202 return instance->AddStream (stream);
2206 void
2207 external_demuxer_clear_callbacks (ExternalDemuxer *instance)
2209 if (instance == NULL)
2210 return;
2212 instance->ClearCallbacks ();
2216 void
2217 external_demuxer_set_can_seek (ExternalDemuxer *instance, bool value)
2219 if (instance == NULL)
2220 return;
2222 instance->SetCanSeek (value);
2227 * ExternalPart
2229 ExternalPart *
2230 external_part_new (void)
2232 return new ExternalPart ();
2237 * ExternalPartCollection
2239 ExternalPartCollection *
2240 external_part_collection_new (void)
2242 return new ExternalPartCollection ();
2247 * FrameworkElement
2249 bool
2250 framework_element_apply_template (FrameworkElement *instance)
2252 if (instance == NULL)
2253 return false;
2255 return instance->ApplyTemplate ();
2259 Size
2260 framework_element_arrange_override (FrameworkElement *instance, Size finalSize)
2262 if (instance == NULL)
2263 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2264 return (Size) 0;
2266 return instance->ArrangeOverride (finalSize);
2270 FrameworkElement *
2271 framework_element_new (void)
2273 return new FrameworkElement ();
2277 DependencyObject *
2278 framework_element_get_logical_parent (FrameworkElement *instance)
2280 if (instance == NULL)
2281 return NULL;
2283 return instance->GetLogicalParent ();
2287 Size
2288 framework_element_measure_override (FrameworkElement *instance, Size availableSize)
2290 if (instance == NULL)
2291 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2292 return (Size) 0;
2294 return instance->MeasureOverride (availableSize);
2298 void
2299 framework_element_register_managed_overrides (FrameworkElement *instance, MeasureOverrideCallback measure_cb, ArrangeOverrideCallback arrange_cb, GetDefaultTemplateCallback get_default_template_cb, LoadedCallback loaded_cb)
2301 if (instance == NULL)
2302 return;
2304 instance->RegisterManagedOverrides (measure_cb, arrange_cb, get_default_template_cb, loaded_cb);
2308 void
2309 framework_element_set_default_style (FrameworkElement *instance, Style *value)
2311 if (instance == NULL)
2312 return;
2314 instance->SetDefaultStyle (value);
2318 void
2319 framework_element_set_logical_parent (FrameworkElement *instance, DependencyObject *logical_parent, MoonError *error)
2321 if (instance == NULL)
2322 return;
2324 if (error == NULL)
2325 g_warning ("Moonlight: Called framework_element_set_logical_parent () with error == NULL.");
2326 instance->SetLogicalParent (logical_parent, error);
2331 * FrameworkTemplate
2333 FrameworkTemplate *
2334 framework_template_new (void)
2336 return new FrameworkTemplate ();
2340 DependencyObject *
2341 framework_template_get_visual_tree (FrameworkTemplate *instance, FrameworkElement *templateBindingSource)
2343 if (instance == NULL)
2344 return NULL;
2346 return instance->GetVisualTree (templateBindingSource);
2351 * GeneralTransform
2353 GeneralTransform *
2354 general_transform_new (void)
2356 return new GeneralTransform ();
2360 Matrix *
2361 general_transform_get_matrix (GeneralTransform *instance)
2363 if (instance == NULL)
2364 return NULL;
2366 return instance->GetMatrix ();
2371 * Geometry
2373 Geometry *
2374 geometry_new (void)
2376 return new Geometry ();
2380 Rect
2381 geometry_get_bounds (Geometry *instance)
2383 if (instance == NULL)
2384 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2385 return (Rect) 0;
2387 return instance->GetBounds ();
2392 * GeometryCollection
2394 GeometryCollection *
2395 geometry_collection_new (void)
2397 return new GeometryCollection ();
2402 * GeometryGroup
2404 GeometryGroup *
2405 geometry_group_new (void)
2407 return new GeometryGroup ();
2412 * Glyphs
2414 Glyphs *
2415 glyphs_new (void)
2417 return new Glyphs ();
2422 * GradientBrush
2424 GradientBrush *
2425 gradient_brush_new (void)
2427 return new GradientBrush ();
2432 * GradientStop
2434 GradientStop *
2435 gradient_stop_new (void)
2437 return new GradientStop ();
2442 * GradientStopCollection
2444 GradientStopCollection *
2445 gradient_stop_collection_new (void)
2447 return new GradientStopCollection ();
2452 * Grid
2454 Grid *
2455 grid_new (void)
2457 return new Grid ();
2462 * HitTestCollection
2464 HitTestCollection *
2465 hit_test_collection_new (void)
2467 return new HitTestCollection ();
2472 * Icon
2474 Icon *
2475 icon_new (void)
2477 return new Icon ();
2482 * IconCollection
2484 IconCollection *
2485 icon_collection_new (void)
2487 return new IconCollection ();
2492 * Image
2494 Image *
2495 image_new (void)
2497 return new Image ();
2501 void
2502 image_set_source (Image *instance, ImageSource *source)
2504 if (instance == NULL)
2505 return;
2507 instance->SetSource (source);
2512 * ImageBrush
2514 ImageBrush *
2515 image_brush_new (void)
2517 return new ImageBrush ();
2522 * ImageSource
2524 ImageSource *
2525 image_source_new (void)
2527 return new ImageSource ();
2532 * IMediaDecoder
2534 void
2535 imedia_decoder_report_decode_frame_completed (IMediaDecoder *instance, MediaFrame *frame)
2537 if (instance == NULL)
2538 return;
2540 instance->ReportDecodeFrameCompleted (frame);
2544 void
2545 imedia_decoder_report_open_decoder_completed (IMediaDecoder *instance)
2547 if (instance == NULL)
2548 return;
2550 instance->ReportOpenDecoderCompleted ();
2554 void
2555 imedia_decoder_set_pixel_format (IMediaDecoder *instance, int value)
2557 if (instance == NULL)
2558 return;
2560 instance->SetPixelFormat ((MoonPixelFormat) value);
2565 * IMediaDemuxer
2567 void
2568 imedia_demuxer_report_get_diagnostic_completed (IMediaDemuxer *instance, int diagnosticKind, gint64 diagnosticValue)
2570 if (instance == NULL)
2571 return;
2573 instance->ReportGetDiagnosticCompleted ((MediaStreamSourceDiagnosticKind) diagnosticKind, diagnosticValue);
2577 void
2578 imedia_demuxer_report_get_frame_completed (IMediaDemuxer *instance, MediaFrame *frame)
2580 if (instance == NULL)
2581 return;
2583 instance->ReportGetFrameCompleted (frame);
2587 void
2588 imedia_demuxer_report_get_frame_progress (IMediaDemuxer *instance, double bufferingProgress)
2590 if (instance == NULL)
2591 return;
2593 instance->ReportGetFrameProgress (bufferingProgress);
2597 void
2598 imedia_demuxer_report_open_demuxer_completed (IMediaDemuxer *instance)
2600 if (instance == NULL)
2601 return;
2603 instance->ReportOpenDemuxerCompleted ();
2607 void
2608 imedia_demuxer_report_seek_completed (IMediaDemuxer *instance, guint64 pts)
2610 if (instance == NULL)
2611 return;
2613 instance->ReportSeekCompleted (pts);
2617 void
2618 imedia_demuxer_report_switch_media_stream_completed (IMediaDemuxer *instance, IMediaStream *stream)
2620 if (instance == NULL)
2621 return;
2623 instance->ReportSwitchMediaStreamCompleted (stream);
2628 * IMediaObject
2630 Media *
2631 imedia_object_get_media_reffed (IMediaObject *instance)
2633 if (instance == NULL)
2634 return NULL;
2636 return instance->GetMediaReffed ();
2640 void
2641 imedia_object_report_error_occurred (IMediaObject *instance, const char *message)
2643 if (instance == NULL)
2644 return;
2646 instance->ReportErrorOccurred (message);
2651 * IMediaStream
2653 const char *
2654 imedia_stream_get_codec (IMediaStream *instance)
2656 if (instance == NULL)
2657 return NULL;
2659 return instance->GetCodec ();
2664 imedia_stream_get_codec_id (IMediaStream *instance)
2666 if (instance == NULL)
2667 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2668 return (int) 0;
2670 return instance->GetCodecId ();
2674 guint64
2675 imedia_stream_get_duration (IMediaStream *instance)
2677 if (instance == NULL)
2678 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2679 return (guint64) 0;
2681 return instance->GetDuration ();
2685 void *
2686 imedia_stream_get_extra_data (IMediaStream *instance)
2688 if (instance == NULL)
2689 return NULL;
2691 return instance->GetExtraData ();
2696 imedia_stream_get_extra_data_size (IMediaStream *instance)
2698 if (instance == NULL)
2699 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2700 return (int) 0;
2702 return instance->GetExtraDataSize ();
2707 imedia_stream_get_stream_type (IMediaStream *instance)
2709 if (instance == NULL)
2710 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2711 return (MediaStreamType) 0;
2713 return instance->GetStreamType ();
2717 void
2718 imedia_stream_set_codec_id (IMediaStream *instance, int value)
2720 if (instance == NULL)
2721 return;
2723 instance->SetCodecId (value);
2727 void
2728 imedia_stream_set_duration (IMediaStream *instance, guint64 value)
2730 if (instance == NULL)
2731 return;
2733 instance->SetDuration (value);
2737 void
2738 imedia_stream_set_extra_data (IMediaStream *instance, void *value)
2740 if (instance == NULL)
2741 return;
2743 instance->SetExtraData (value);
2747 void
2748 imedia_stream_set_extra_data_size (IMediaStream *instance, int value)
2750 if (instance == NULL)
2751 return;
2753 instance->SetExtraDataSize (value);
2758 * InkPresenter
2760 InkPresenter *
2761 ink_presenter_new (void)
2763 return new InkPresenter ();
2768 * Inline
2770 Inline *
2771 inline_new (void)
2773 return new Inline ();
2778 * InlineCollection
2780 InlineCollection *
2781 inline_collection_new (void)
2783 return new InlineCollection ();
2788 * InputMethod
2790 InputMethod *
2791 input_method_new (void)
2793 return new InputMethod ();
2798 * ItemCollection
2800 ItemCollection *
2801 item_collection_new (void)
2803 return new ItemCollection ();
2808 * Keyboard
2811 keyboard_get_modifiers (void)
2813 return Keyboard::GetModifiers ();
2818 * KeyEventArgs
2821 key_event_args_get_key (KeyEventArgs *instance)
2823 if (instance == NULL)
2824 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2825 return (int) 0;
2827 return instance->GetKey ();
2832 key_event_args_get_platform_key_code (KeyEventArgs *instance)
2834 if (instance == NULL)
2835 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2836 return (int) 0;
2838 return instance->GetPlatformKeyCode ();
2842 KeyEventArgs *
2843 key_event_args_new (void)
2845 return new KeyEventArgs ();
2850 * KeyFrameCollection
2852 KeyFrameCollection *
2853 key_frame_collection_new (void)
2855 return new KeyFrameCollection ();
2860 * KeySpline
2862 KeySpline *
2863 key_spline_new (void)
2865 return new KeySpline ();
2870 * Line
2872 Line *
2873 line_new (void)
2875 return new Line ();
2880 * LinearColorKeyFrame
2882 LinearColorKeyFrame *
2883 linear_color_key_frame_new (void)
2885 return new LinearColorKeyFrame ();
2890 * LinearDoubleKeyFrame
2892 LinearDoubleKeyFrame *
2893 linear_double_key_frame_new (void)
2895 return new LinearDoubleKeyFrame ();
2900 * LinearGradientBrush
2902 LinearGradientBrush *
2903 linear_gradient_brush_new (void)
2905 return new LinearGradientBrush ();
2910 * LinearPointKeyFrame
2912 LinearPointKeyFrame *
2913 linear_point_key_frame_new (void)
2915 return new LinearPointKeyFrame ();
2920 * LineBreak
2922 LineBreak *
2923 line_break_new (void)
2925 return new LineBreak ();
2930 * LineGeometry
2932 LineGeometry *
2933 line_geometry_new (void)
2935 return new LineGeometry ();
2940 * LineSegment
2942 LineSegment *
2943 line_segment_new (void)
2945 return new LineSegment ();
2950 * LogReadyRoutedEventArgs
2952 LogReadyRoutedEventArgs *
2953 log_ready_routed_event_args_new (void)
2955 return new LogReadyRoutedEventArgs ();
2960 * Matrix
2962 cairo_matrix_t *
2963 matrix_get_matrix_values (Matrix *instance)
2965 if (instance == NULL)
2966 return NULL;
2968 return instance->GetMatrixValues ();
2972 Matrix *
2973 matrix_new (void)
2975 return new Matrix ();
2980 * Matrix3D
2982 gpointer
2983 matrix3_d_get_matrix_values (Matrix3D *instance)
2985 if (instance == NULL)
2986 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
2987 return (gpointer) 0;
2989 return instance->GetMatrixValues ();
2993 Matrix3D *
2994 matrix3_d_new (void)
2996 return new Matrix3D ();
3001 * Matrix3DProjection
3003 Matrix3DProjection *
3004 matrix3_dprojection_new (void)
3006 return new Matrix3DProjection ();
3011 * MatrixTransform
3013 MatrixTransform *
3014 matrix_transform_new (void)
3016 return new MatrixTransform ();
3021 * Media
3023 void
3024 media_register_decoder (DecoderInfo *info)
3026 Media::RegisterDecoder (info);
3031 * MediaAttribute
3033 MediaAttribute *
3034 media_attribute_new (void)
3036 return new MediaAttribute ();
3041 * MediaAttributeCollection
3043 MediaAttribute *
3044 media_attribute_collection_get_item_by_name (MediaAttributeCollection *instance, const char *name)
3046 if (instance == NULL)
3047 return NULL;
3049 return instance->GetItemByName (name);
3053 MediaAttributeCollection *
3054 media_attribute_collection_new (void)
3056 return new MediaAttributeCollection ();
3061 * MediaBase
3063 MediaBase *
3064 media_base_new (void)
3066 return new MediaBase ();
3070 void
3071 media_base_set_source (MediaBase *instance, const char *uri)
3073 if (instance == NULL)
3074 return;
3076 instance->SetSource (uri);
3081 * MediaElement
3083 MediaElement *
3084 media_element_new (void)
3086 return new MediaElement ();
3090 void
3091 media_element_pause (MediaElement *instance)
3093 if (instance == NULL)
3094 return;
3096 instance->Pause ();
3100 void
3101 media_element_play (MediaElement *instance)
3103 if (instance == NULL)
3104 return;
3106 instance->Play ();
3110 void
3111 media_element_report_error_occurred (MediaElement *instance, const char *args)
3113 if (instance == NULL)
3114 return;
3116 instance->ReportErrorOccurred (args);
3120 IMediaDemuxer *
3121 media_element_set_demuxer_source (MediaElement *instance, void *context, CloseDemuxerCallback close_demuxer, GetDiagnosticAsyncCallback get_diagnostic, GetFrameAsyncCallback get_sample, OpenDemuxerAsyncCallback open_demuxer, SeekAsyncCallback seek, SwitchMediaStreamAsyncCallback switch_media_stream)
3123 if (instance == NULL)
3124 return NULL;
3126 return instance->SetDemuxerSource (context, close_demuxer, get_diagnostic, get_sample, open_demuxer, seek, switch_media_stream);
3130 void
3131 media_element_set_stream_source (MediaElement *instance, ManagedStreamCallbacks *stream)
3133 if (instance == NULL)
3134 return;
3136 instance->SetStreamSource (stream);
3140 void
3141 media_element_stop (MediaElement *instance)
3143 if (instance == NULL)
3144 return;
3146 instance->Stop ();
3151 * MediaFrame
3153 void
3154 media_frame_add_state (MediaFrame *instance, int state)
3156 if (instance == NULL)
3157 return;
3159 instance->AddState ((MediaFrameState) state);
3163 guint8 *
3164 media_frame_get_buffer (MediaFrame *instance)
3166 if (instance == NULL)
3167 return NULL;
3169 return instance->GetBuffer ();
3173 guint32
3174 media_frame_get_buf_len (MediaFrame *instance)
3176 if (instance == NULL)
3177 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3178 return (guint32) 0;
3180 return instance->GetBufLen ();
3184 gint32
3185 media_frame_get_height (MediaFrame *instance)
3187 if (instance == NULL)
3188 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3189 return (gint32) 0;
3191 return instance->GetHeight ();
3195 guint64
3196 media_frame_get_pts (MediaFrame *instance)
3198 if (instance == NULL)
3199 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3200 return (guint64) 0;
3202 return instance->GetPts ();
3206 gint32
3207 media_frame_get_width (MediaFrame *instance)
3209 if (instance == NULL)
3210 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3211 return (gint32) 0;
3213 return instance->GetWidth ();
3217 bool
3218 media_frame_is_key_frame (MediaFrame *instance)
3220 if (instance == NULL)
3221 return false;
3223 return instance->IsKeyFrame ();
3227 MediaFrame *
3228 media_frame_new (IMediaStream *stream, guint8 *buffer, guint32 buflen, guint64 pts, bool keyframe)
3230 return new MediaFrame (stream, buffer, buflen, pts, keyframe);
3234 void
3235 media_frame_set_buffer (MediaFrame *instance, guint8 *value)
3237 if (instance == NULL)
3238 return;
3240 instance->SetBuffer (value);
3244 void
3245 media_frame_set_buf_len (MediaFrame *instance, guint32 value)
3247 if (instance == NULL)
3248 return;
3250 instance->SetBufLen (value);
3254 void
3255 media_frame_set_data_stride (MediaFrame *instance, guint8 *a, guint8 *b, guint8 *c, guint8 *d)
3257 if (instance == NULL)
3258 return;
3260 instance->SetDataStride (a, b, c, d);
3264 void
3265 media_frame_set_decoder_specific_data (MediaFrame *instance, void *value)
3267 if (instance == NULL)
3268 return;
3270 instance->SetDecoderSpecificData (value);
3274 void
3275 media_frame_set_height (MediaFrame *instance, gint32 value)
3277 if (instance == NULL)
3278 return;
3280 instance->SetHeight (value);
3284 void
3285 media_frame_set_pts (MediaFrame *instance, guint64 value)
3287 if (instance == NULL)
3288 return;
3290 instance->SetPts (value);
3294 void
3295 media_frame_set_src_slide_h (MediaFrame *instance, int value)
3297 if (instance == NULL)
3298 return;
3300 instance->SetSrcSlideH (value);
3304 void
3305 media_frame_set_src_slide_y (MediaFrame *instance, int value)
3307 if (instance == NULL)
3308 return;
3310 instance->SetSrcSlideY (value);
3314 void
3315 media_frame_set_src_stride (MediaFrame *instance, int a, int b, int c, int d)
3317 if (instance == NULL)
3318 return;
3320 instance->SetSrcStride (a, b, c, d);
3324 void
3325 media_frame_set_width (MediaFrame *instance, gint32 value)
3327 if (instance == NULL)
3328 return;
3330 instance->SetWidth (value);
3335 * MoonWindow
3337 bool
3338 moon_window_get_transparent (MoonWindow *instance)
3340 if (instance == NULL)
3341 return false;
3343 return instance->GetTransparent ();
3347 void
3348 moon_window_set_transparent (MoonWindow *instance, bool flag)
3350 if (instance == NULL)
3351 return;
3353 instance->SetTransparent (flag);
3358 * MoonWindowGtk
3360 void *
3361 moon_window_gtk_get_native_widget (MoonWindowGtk *instance)
3363 if (instance == NULL)
3364 return NULL;
3366 return instance->GetNativeWidget ();
3370 MoonWindowGtk *
3371 moon_window_gtk_new (bool fullscreen, int w, int h, MoonWindow *parent, Surface *surface)
3373 return new MoonWindowGtk (fullscreen, w, h, parent, surface);
3378 * MouseButtonEventArgs
3380 MouseButtonEventArgs *
3381 mouse_button_event_args_new (void)
3383 return new MouseButtonEventArgs ();
3388 * MouseEventArgs
3390 void
3391 mouse_event_args_get_position (MouseEventArgs *instance, UIElement *relative_to, double *x, double *y)
3393 if (instance == NULL)
3394 return;
3396 instance->GetPosition (relative_to, x, y);
3400 StylusInfo *
3401 mouse_event_args_get_stylus_info (MouseEventArgs *instance)
3403 if (instance == NULL)
3404 return NULL;
3406 return instance->GetStylusInfo ();
3410 StylusPointCollection *
3411 mouse_event_args_get_stylus_points (MouseEventArgs *instance, UIElement *ink_presenter)
3413 if (instance == NULL)
3414 return NULL;
3416 return instance->GetStylusPoints (ink_presenter);
3420 MouseEventArgs *
3421 mouse_event_args_new (void)
3423 return new MouseEventArgs ();
3428 * MouseWheelEventArgs
3431 mouse_wheel_event_args_get_wheel_delta (MouseWheelEventArgs *instance)
3433 if (instance == NULL)
3434 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3435 return (int) 0;
3437 return instance->GetWheelDelta ();
3441 MouseWheelEventArgs *
3442 mouse_wheel_event_args_new (void)
3444 return new MouseWheelEventArgs ();
3449 * MultiScaleImage
3451 Point
3452 multi_scale_image_element_to_logical_point (MultiScaleImage *instance, Point elementPoint)
3454 if (instance == NULL)
3455 return Point (0, 0);
3457 return instance->ElementToLogicalPoint (elementPoint);
3461 void
3462 multi_scale_image_emit_image_failed (MultiScaleImage *instance)
3464 if (instance == NULL)
3465 return;
3467 instance->EmitImageFailed ();
3471 void
3472 multi_scale_image_emit_image_open_failed (MultiScaleImage *instance)
3474 if (instance == NULL)
3475 return;
3477 instance->EmitImageOpenFailed ();
3481 void
3482 multi_scale_image_emit_motion_finished (MultiScaleImage *instance)
3484 if (instance == NULL)
3485 return;
3487 instance->EmitMotionFinished ();
3491 void
3492 multi_scale_image_handle_dz_parsed (MultiScaleImage *instance)
3494 if (instance == NULL)
3495 return;
3497 instance->HandleDzParsed ();
3501 void
3502 multi_scale_image_invalidate_tile_layer (MultiScaleImage *instance, int level, int tilePositionX, int tilePositionY, int tileLayer)
3504 if (instance == NULL)
3505 return;
3507 instance->InvalidateTileLayer (level, tilePositionX, tilePositionY, tileLayer);
3511 Point
3512 multi_scale_image_logical_to_element_point (MultiScaleImage *instance, Point logicalPoint)
3514 if (instance == NULL)
3515 return Point (0, 0);
3517 return instance->LogicalToElementPoint (logicalPoint);
3521 MultiScaleImage *
3522 multi_scale_image_new (void)
3524 return new MultiScaleImage ();
3528 void
3529 multi_scale_image_on_source_property_changed (MultiScaleImage *instance)
3531 if (instance == NULL)
3532 return;
3534 instance->OnSourcePropertyChanged ();
3538 void
3539 multi_scale_image_zoom_about_logical_point (MultiScaleImage *instance, double zoomIncrementFactor, double zoomCenterLogicalX, double zoomCenterLogicalY)
3541 if (instance == NULL)
3542 return;
3544 instance->ZoomAboutLogicalPoint (zoomIncrementFactor, zoomCenterLogicalX, zoomCenterLogicalY);
3549 * MultiScaleSubImage
3551 gint32
3552 multi_scale_sub_image_get_zindex (MultiScaleSubImage *instance)
3554 if (instance == NULL)
3555 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3556 return (gint32) 0;
3558 return instance->GetZIndex ();
3562 MultiScaleSubImage *
3563 multi_scale_sub_image_new (void)
3565 return new MultiScaleSubImage ();
3570 * MultiScaleSubImageCollection
3572 MultiScaleSubImageCollection *
3573 multi_scale_sub_image_collection_new (void)
3575 return new MultiScaleSubImageCollection ();
3580 * MultiScaleTileSource
3582 void
3583 multi_scale_tile_source_invalidate_tile_layer (MultiScaleTileSource *instance, int level, int tilePositionX, int tilePositionY, int tileLayer)
3585 if (instance == NULL)
3586 return;
3588 instance->InvalidateTileLayer (level, tilePositionX, tilePositionY, tileLayer);
3592 MultiScaleTileSource *
3593 multi_scale_tile_source_new (void)
3595 return new MultiScaleTileSource ();
3599 void
3600 multi_scale_tile_source_set_image_uri_func (MultiScaleTileSource *instance, get_image_uri_func func)
3602 if (instance == NULL)
3603 return;
3605 instance->set_image_uri_func (func);
3610 * NameScope
3612 NameScope *
3613 name_scope_new (void)
3615 return new NameScope ();
3620 * ObjectAnimationUsingKeyFrames
3622 ObjectAnimationUsingKeyFrames *
3623 object_animation_using_key_frames_new (void)
3625 return new ObjectAnimationUsingKeyFrames ();
3630 * ObjectKeyFrame
3632 ObjectKeyFrame *
3633 object_key_frame_new (void)
3635 return new ObjectKeyFrame ();
3640 * ObjectKeyFrameCollection
3642 ObjectKeyFrameCollection *
3643 object_key_frame_collection_new (void)
3645 return new ObjectKeyFrameCollection ();
3650 * OutOfBrowserSettings
3652 OutOfBrowserSettings *
3653 out_of_browser_settings_new (void)
3655 return new OutOfBrowserSettings ();
3660 * Panel
3662 Panel *
3663 panel_new (void)
3665 return new Panel ();
3670 * ParallelTimeline
3672 ParallelTimeline *
3673 parallel_timeline_new (void)
3675 return new ParallelTimeline ();
3680 * PasswordBox
3682 PasswordBox *
3683 password_box_new (void)
3685 return new PasswordBox ();
3690 * Path
3692 Path *
3693 path_new (void)
3695 return new Path ();
3700 * PathFigure
3702 PathFigure *
3703 path_figure_new (void)
3705 return new PathFigure ();
3710 * PathFigureCollection
3712 PathFigureCollection *
3713 path_figure_collection_new (void)
3715 return new PathFigureCollection ();
3720 * PathGeometry
3722 PathGeometry *
3723 path_geometry_new (void)
3725 return new PathGeometry ();
3730 * PathSegment
3732 PathSegment *
3733 path_segment_new (void)
3735 return new PathSegment ();
3740 * PathSegmentCollection
3742 PathSegmentCollection *
3743 path_segment_collection_new (void)
3745 return new PathSegmentCollection ();
3750 * PixelShader
3752 PixelShader *
3753 pixel_shader_new (void)
3755 return new PixelShader ();
3760 * PlaneProjection
3762 PlaneProjection *
3763 plane_projection_new (void)
3765 return new PlaneProjection ();
3770 * PointAnimation
3772 PointAnimation *
3773 point_animation_new (void)
3775 return new PointAnimation ();
3780 * PointAnimationUsingKeyFrames
3782 PointAnimationUsingKeyFrames *
3783 point_animation_using_key_frames_new (void)
3785 return new PointAnimationUsingKeyFrames ();
3790 * PointCollection
3792 PointCollection *
3793 point_collection_new (void)
3795 return new PointCollection ();
3800 * PointKeyFrame
3802 PointKeyFrame *
3803 point_key_frame_new (void)
3805 return new PointKeyFrame ();
3810 * PointKeyFrameCollection
3812 PointKeyFrameCollection *
3813 point_key_frame_collection_new (void)
3815 return new PointKeyFrameCollection ();
3820 * PolyBezierSegment
3822 PolyBezierSegment *
3823 poly_bezier_segment_new (void)
3825 return new PolyBezierSegment ();
3829 void
3830 poly_bezier_segment_set_points (PolyBezierSegment *instance, PointCollection *points)
3832 if (instance == NULL)
3833 return;
3835 instance->SetPoints (points);
3840 * Polygon
3842 Polygon *
3843 polygon_new (void)
3845 return new Polygon ();
3850 * Polyline
3852 Polyline *
3853 polyline_new (void)
3855 return new Polyline ();
3860 * PolyLineSegment
3862 PolyLineSegment *
3863 poly_line_segment_new (void)
3865 return new PolyLineSegment ();
3870 * PolyQuadraticBezierSegment
3872 PolyQuadraticBezierSegment *
3873 poly_quadratic_bezier_segment_new (void)
3875 return new PolyQuadraticBezierSegment ();
3880 * Popup
3882 Popup *
3883 popup_new (void)
3885 return new Popup ();
3890 * PowerEase
3892 double
3893 power_ease_ease_in_core (PowerEase *instance, double normalizedTime)
3895 if (instance == NULL)
3896 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3897 return (double) 0;
3899 return instance->EaseInCore (normalizedTime);
3903 PowerEase *
3904 power_ease_new (void)
3906 return new PowerEase ();
3911 * Projection
3913 Projection *
3914 projection_new (void)
3916 return new Projection ();
3921 * PropertyChangedEventArgs
3924 property_changed_event_args_get_id (PropertyChangedEventArgs *instance)
3926 if (instance == NULL)
3927 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3928 return (int) 0;
3930 return instance->GetId ();
3934 Value *
3935 property_changed_event_args_get_new_value (PropertyChangedEventArgs *instance)
3937 if (instance == NULL)
3938 return NULL;
3940 return instance->GetNewValue ();
3944 Value *
3945 property_changed_event_args_get_old_value (PropertyChangedEventArgs *instance)
3947 if (instance == NULL)
3948 return NULL;
3950 return instance->GetOldValue ();
3954 DependencyProperty *
3955 property_changed_event_args_get_property (PropertyChangedEventArgs *instance)
3957 if (instance == NULL)
3958 return NULL;
3960 return instance->GetProperty ();
3965 * QuadraticBezierSegment
3967 QuadraticBezierSegment *
3968 quadratic_bezier_segment_new (void)
3970 return new QuadraticBezierSegment ();
3975 * QuadraticEase
3977 double
3978 quadratic_ease_ease_in_core (QuadraticEase *instance, double normalizedTime)
3980 if (instance == NULL)
3981 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
3982 return (double) 0;
3984 return instance->EaseInCore (normalizedTime);
3988 QuadraticEase *
3989 quadratic_ease_new (void)
3991 return new QuadraticEase ();
3996 * QuarticEase
3998 double
3999 quartic_ease_ease_in_core (QuarticEase *instance, double normalizedTime)
4001 if (instance == NULL)
4002 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4003 return (double) 0;
4005 return instance->EaseInCore (normalizedTime);
4009 QuarticEase *
4010 quartic_ease_new (void)
4012 return new QuarticEase ();
4017 * QuinticEase
4019 double
4020 quintic_ease_ease_in_core (QuinticEase *instance, double normalizedTime)
4022 if (instance == NULL)
4023 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4024 return (double) 0;
4026 return instance->EaseInCore (normalizedTime);
4030 QuinticEase *
4031 quintic_ease_new (void)
4033 return new QuinticEase ();
4038 * RadialGradientBrush
4040 RadialGradientBrush *
4041 radial_gradient_brush_new (void)
4043 return new RadialGradientBrush ();
4048 * Rectangle
4050 Rectangle *
4051 rectangle_new (void)
4053 return new Rectangle ();
4058 * RectangleGeometry
4060 RectangleGeometry *
4061 rectangle_geometry_new (void)
4063 return new RectangleGeometry ();
4068 * RenderingEventArgs
4070 TimeSpan
4071 rendering_event_args_get_rendering_time (RenderingEventArgs *instance)
4073 if (instance == NULL)
4074 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4075 return (TimeSpan) 0;
4077 return instance->GetRenderingTime ();
4082 * ResourceDictionary
4084 bool
4085 resource_dictionary_add_with_error (ResourceDictionary *instance, const char *key, Value *value, MoonError *error)
4087 if (instance == NULL)
4088 return false;
4090 if (error == NULL)
4091 g_warning ("Moonlight: Called resource_dictionary_add_with_error () with error == NULL.");
4092 return instance->AddWithError (key, value, error);
4096 bool
4097 resource_dictionary_clear (ResourceDictionary *instance)
4099 if (instance == NULL)
4100 return false;
4102 return instance->Clear ();
4106 bool
4107 resource_dictionary_contains_key (ResourceDictionary *instance, const char *key)
4109 if (instance == NULL)
4110 return false;
4112 return instance->ContainsKey (key);
4116 Value *
4117 resource_dictionary_get (ResourceDictionary *instance, const char *key, bool *exists)
4119 if (instance == NULL)
4120 return NULL;
4122 return instance->Get (key, exists);
4126 bool
4127 resource_dictionary_remove (ResourceDictionary *instance, const char *key)
4129 if (instance == NULL)
4130 return false;
4132 return instance->Remove (key);
4136 ResourceDictionary *
4137 resource_dictionary_new (void)
4139 return new ResourceDictionary ();
4143 bool
4144 resource_dictionary_set (ResourceDictionary *instance, const char *key, Value *value)
4146 if (instance == NULL)
4147 return false;
4149 return instance->Set (key, value);
4154 * ResourceDictionaryCollection
4156 ResourceDictionaryCollection *
4157 resource_dictionary_collection_new (void)
4159 return new ResourceDictionaryCollection ();
4164 * RotateTransform
4166 RotateTransform *
4167 rotate_transform_new (void)
4169 return new RotateTransform ();
4174 * RoutedEventArgs
4176 bool
4177 routed_event_args_get_handled (RoutedEventArgs *instance)
4179 if (instance == NULL)
4180 return false;
4182 return instance->GetHandled ();
4186 DependencyObject *
4187 routed_event_args_get_source (RoutedEventArgs *instance)
4189 if (instance == NULL)
4190 return NULL;
4192 return instance->GetSource ();
4196 RoutedEventArgs *
4197 routed_event_args_new (void)
4199 return new RoutedEventArgs ();
4203 void
4204 routed_event_args_set_handled (RoutedEventArgs *instance, bool handled)
4206 if (instance == NULL)
4207 return;
4209 instance->SetHandled (handled);
4213 void
4214 routed_event_args_set_source (RoutedEventArgs *instance, DependencyObject *el)
4216 if (instance == NULL)
4217 return;
4219 instance->SetSource (el);
4224 * RowDefinition
4226 RowDefinition *
4227 row_definition_new (void)
4229 return new RowDefinition ();
4234 * RowDefinitionCollection
4236 RowDefinitionCollection *
4237 row_definition_collection_new (void)
4239 return new RowDefinitionCollection ();
4244 * Run
4246 Run *
4247 run_new (void)
4249 return new Run ();
4254 * ScaleTransform
4256 ScaleTransform *
4257 scale_transform_new (void)
4259 return new ScaleTransform ();
4264 * Setter
4266 Setter *
4267 setter_new (void)
4269 return new Setter ();
4274 * SetterBase
4276 SetterBase *
4277 setter_base_new (void)
4279 return new SetterBase ();
4284 * SetterBaseCollection
4286 SetterBaseCollection *
4287 setter_base_collection_new (void)
4289 return new SetterBaseCollection ();
4294 * ShaderEffect
4296 ShaderEffect *
4297 shader_effect_new (void)
4299 return new ShaderEffect ();
4304 * Shape
4306 Transform *
4307 shape_get_geometry_transform (Shape *instance)
4309 if (instance == NULL)
4310 return NULL;
4312 return instance->GetGeometryTransform ();
4316 Shape *
4317 shape_new (void)
4319 return new Shape ();
4324 * SineEase
4326 double
4327 sine_ease_ease_in_core (SineEase *instance, double normalizedTime)
4329 if (instance == NULL)
4330 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4331 return (double) 0;
4333 return instance->EaseInCore (normalizedTime);
4337 SineEase *
4338 sine_ease_new (void)
4340 return new SineEase ();
4345 * SizeChangedEventArgs
4347 SizeChangedEventArgs *
4348 size_changed_event_args_new (void)
4350 return new SizeChangedEventArgs ();
4355 * SkewTransform
4357 SkewTransform *
4358 skew_transform_new (void)
4360 return new SkewTransform ();
4365 * SolidColorBrush
4367 SolidColorBrush *
4368 solid_color_brush_new (void)
4370 return new SolidColorBrush ();
4375 * SplineColorKeyFrame
4377 SplineColorKeyFrame *
4378 spline_color_key_frame_new (void)
4380 return new SplineColorKeyFrame ();
4385 * SplineDoubleKeyFrame
4387 SplineDoubleKeyFrame *
4388 spline_double_key_frame_new (void)
4390 return new SplineDoubleKeyFrame ();
4395 * SplinePointKeyFrame
4397 SplinePointKeyFrame *
4398 spline_point_key_frame_new (void)
4400 return new SplinePointKeyFrame ();
4405 * Storyboard
4407 bool
4408 storyboard_begin_with_error (Storyboard *instance, MoonError *error)
4410 if (instance == NULL)
4411 return false;
4413 if (error == NULL)
4414 g_warning ("Moonlight: Called storyboard_begin_with_error () with error == NULL.");
4415 return instance->BeginWithError (error);
4420 storyboard_get_current_state (Storyboard *instance)
4422 if (instance == NULL)
4423 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4424 return (int) 0;
4426 return instance->GetCurrentState ();
4430 TimeSpan
4431 storyboard_get_current_time (Storyboard *instance)
4433 if (instance == NULL)
4434 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4435 return (TimeSpan) 0;
4437 return instance->GetCurrentTime ();
4441 DependencyProperty *
4442 storyboard_get_target_dependency_property (Storyboard *instance)
4444 if (instance == NULL)
4445 return NULL;
4447 return instance->GetTargetDependencyProperty ();
4451 void
4452 storyboard_pause_with_error (Storyboard *instance, MoonError *error)
4454 if (instance == NULL)
4455 return;
4457 if (error == NULL)
4458 g_warning ("Moonlight: Called storyboard_pause_with_error () with error == NULL.");
4459 instance->PauseWithError (error);
4463 void
4464 storyboard_resume_with_error (Storyboard *instance, MoonError *error)
4466 if (instance == NULL)
4467 return;
4469 if (error == NULL)
4470 g_warning ("Moonlight: Called storyboard_resume_with_error () with error == NULL.");
4471 instance->ResumeWithError (error);
4475 void
4476 storyboard_seek_aligned_to_last_tick_with_error (Storyboard *instance, TimeSpan timespan, MoonError *error)
4478 if (instance == NULL)
4479 return;
4481 if (error == NULL)
4482 g_warning ("Moonlight: Called storyboard_seek_aligned_to_last_tick_with_error () with error == NULL.");
4483 instance->SeekAlignedToLastTickWithError (timespan, error);
4487 void
4488 storyboard_seek_with_error (Storyboard *instance, TimeSpan timespan, MoonError *error)
4490 if (instance == NULL)
4491 return;
4493 if (error == NULL)
4494 g_warning ("Moonlight: Called storyboard_seek_with_error () with error == NULL.");
4495 instance->SeekWithError (timespan, error);
4499 void
4500 storyboard_skip_to_fill_with_error (Storyboard *instance, MoonError *error)
4502 if (instance == NULL)
4503 return;
4505 if (error == NULL)
4506 g_warning ("Moonlight: Called storyboard_skip_to_fill_with_error () with error == NULL.");
4507 instance->SkipToFillWithError (error);
4511 void
4512 storyboard_stop_with_error (Storyboard *instance, MoonError *error)
4514 if (instance == NULL)
4515 return;
4517 if (error == NULL)
4518 g_warning ("Moonlight: Called storyboard_stop_with_error () with error == NULL.");
4519 instance->StopWithError (error);
4523 Storyboard *
4524 storyboard_new (void)
4526 return new Storyboard ();
4531 * Stroke
4533 bool
4534 stroke_hit_test (Stroke *instance, StylusPointCollection *stylusPoints)
4536 if (instance == NULL)
4537 return false;
4539 return instance->HitTest (stylusPoints);
4543 Stroke *
4544 stroke_new (void)
4546 return new Stroke ();
4551 * StrokeCollection
4553 StrokeCollection *
4554 stroke_collection_hit_test (StrokeCollection *instance, StylusPointCollection *stylusPoints)
4556 if (instance == NULL)
4557 return NULL;
4559 return instance->HitTest (stylusPoints);
4563 StrokeCollection *
4564 stroke_collection_new (void)
4566 return new StrokeCollection ();
4571 * Style
4573 void
4574 style_seal (Style *instance)
4576 if (instance == NULL)
4577 return;
4579 instance->Seal ();
4583 Style *
4584 style_new (void)
4586 return new Style ();
4591 * StylusInfo
4593 StylusInfo *
4594 stylus_info_new (void)
4596 return new StylusInfo ();
4601 * StylusPoint
4603 double
4604 stylus_point_get_pressure_factor (StylusPoint *instance)
4606 if (instance == NULL)
4607 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4608 return (double) 0;
4610 return instance->GetPressureFactor ();
4614 double
4615 stylus_point_get_x (StylusPoint *instance)
4617 if (instance == NULL)
4618 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4619 return (double) 0;
4621 return instance->GetX ();
4625 double
4626 stylus_point_get_y (StylusPoint *instance)
4628 if (instance == NULL)
4629 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4630 return (double) 0;
4632 return instance->GetY ();
4636 void
4637 stylus_point_set_pressure_factor (StylusPoint *instance, double factor)
4639 if (instance == NULL)
4640 return;
4642 instance->SetPressureFactor (factor);
4646 void
4647 stylus_point_set_x (StylusPoint *instance, double x)
4649 if (instance == NULL)
4650 return;
4652 instance->SetX (x);
4656 void
4657 stylus_point_set_y (StylusPoint *instance, double y)
4659 if (instance == NULL)
4660 return;
4662 instance->SetY (y);
4666 StylusPoint *
4667 stylus_point_new (void)
4669 return new StylusPoint ();
4674 * StylusPointCollection
4676 double
4677 stylus_point_collection_add_stylus_points (StylusPointCollection *instance, StylusPointCollection *stylusPointCollection)
4679 if (instance == NULL)
4680 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
4681 return (double) 0;
4683 return instance->AddStylusPoints (stylusPointCollection);
4687 StylusPointCollection *
4688 stylus_point_collection_new (void)
4690 return new StylusPointCollection ();
4695 * Surface
4697 void
4698 surface_attach (Surface *instance, UIElement *toplevel)
4700 if (instance == NULL)
4701 return;
4703 instance->Attach (toplevel);
4707 Downloader *
4708 surface_create_downloader (Surface *instance)
4710 if (instance == NULL)
4711 return NULL;
4713 return instance->CreateDownloader ();
4717 void
4718 surface_emit_error (Surface *instance, int number, int code, const char *message)
4720 if (instance == NULL)
4721 return;
4723 instance->EmitError (number, code, message);
4727 Color *
4728 surface_get_background_color (Surface *instance)
4730 if (instance == NULL)
4731 return NULL;
4733 return instance->GetBackgroundColor ();
4737 UIElement *
4738 surface_get_focused_element (Surface *instance)
4740 if (instance == NULL)
4741 return NULL;
4743 return instance->GetFocusedElement ();
4747 bool
4748 surface_get_full_screen (Surface *instance)
4750 if (instance == NULL)
4751 return false;
4753 return instance->GetFullScreen ();
4757 TimeManager *
4758 surface_get_time_manager (Surface *instance)
4760 if (instance == NULL)
4761 return NULL;
4763 return instance->GetTimeManager ();
4767 UIElement *
4768 surface_get_toplevel (Surface *instance)
4770 if (instance == NULL)
4771 return NULL;
4773 return instance->GetToplevel ();
4777 MoonWindow *
4778 surface_get_window (Surface *instance)
4780 if (instance == NULL)
4781 return NULL;
4783 return instance->GetWindow ();
4787 bool
4788 surface_in_main_thread (void)
4790 return Surface::InMainThread ();
4794 bool
4795 surface_is_loaded (Surface *instance)
4797 if (instance == NULL)
4798 return false;
4800 return instance->IsLoaded ();
4804 bool
4805 surface_is_user_initiated_event (Surface *instance)
4807 if (instance == NULL)
4808 return false;
4810 return instance->IsUserInitiatedEvent ();
4814 bool
4815 surface_is_version_supported (const char *version)
4817 return Surface::IsVersionSupported (version);
4821 void
4822 surface_paint (Surface *instance, cairo_t *ctx, int x, int y, int width, int height)
4824 if (instance == NULL)
4825 return;
4827 instance->Paint (ctx, x, y, width, height);
4831 void
4832 surface_resize (Surface *instance, int width, int height)
4834 if (instance == NULL)
4835 return;
4837 instance->Resize (width, height);
4841 void
4842 surface_set_full_screen (Surface *instance, bool value)
4844 if (instance == NULL)
4845 return;
4847 instance->SetFullScreen (value);
4851 Surface *
4852 surface_new (MoonWindow *window)
4854 return new Surface (window);
4859 * TabNavigationWalker
4861 bool
4862 tab_navigation_walker_focus (UIElement *element, bool forwards)
4864 return TabNavigationWalker::Focus (element, forwards);
4869 * TextBlock
4871 TextBlock *
4872 text_block_new (void)
4874 return new TextBlock ();
4879 * TextBox
4881 TextBox *
4882 text_box_new (void)
4884 return new TextBox ();
4889 * TextBoxBase
4891 void
4892 text_box_base_on_got_focus (TextBoxBase *instance, RoutedEventArgs *args)
4894 if (instance == NULL)
4895 return;
4897 instance->OnGotFocus (args);
4901 void
4902 text_box_base_on_key_down (TextBoxBase *instance, KeyEventArgs *args)
4904 if (instance == NULL)
4905 return;
4907 instance->OnKeyDown (args);
4911 void
4912 text_box_base_on_key_up (TextBoxBase *instance, KeyEventArgs *args)
4914 if (instance == NULL)
4915 return;
4917 instance->OnKeyUp (args);
4921 void
4922 text_box_base_on_lost_focus (TextBoxBase *instance, RoutedEventArgs *args)
4924 if (instance == NULL)
4925 return;
4927 instance->OnLostFocus (args);
4931 void
4932 text_box_base_on_mouse_left_button_down (TextBoxBase *instance, MouseButtonEventArgs *args)
4934 if (instance == NULL)
4935 return;
4937 instance->OnMouseLeftButtonDown (args);
4941 void
4942 text_box_base_on_mouse_left_button_up (TextBoxBase *instance, MouseButtonEventArgs *args)
4944 if (instance == NULL)
4945 return;
4947 instance->OnMouseLeftButtonUp (args);
4951 void
4952 text_box_base_on_mouse_move (TextBoxBase *instance, MouseEventArgs *args)
4954 if (instance == NULL)
4955 return;
4957 instance->OnMouseMove (args);
4961 void
4962 text_box_base_post_on_key_down (TextBoxBase *instance, KeyEventArgs *args)
4964 if (instance == NULL)
4965 return;
4967 instance->PostOnKeyDown (args);
4971 void
4972 text_box_base_select_all (TextBoxBase *instance)
4974 if (instance == NULL)
4975 return;
4977 instance->SelectAll ();
4981 bool
4982 text_box_base_select_with_error (TextBoxBase *instance, int start, int length, MoonError *error)
4984 if (instance == NULL)
4985 return false;
4987 if (error == NULL)
4988 g_warning ("Moonlight: Called text_box_base_select_with_error () with error == NULL.");
4989 return instance->SelectWithError (start, length, error);
4994 * TextBoxView
4996 TextBoxView *
4997 text_box_view_new (void)
4999 return new TextBoxView ();
5004 * TextChangedEventArgs
5006 TextChangedEventArgs *
5007 text_changed_event_args_new (void)
5009 return new TextChangedEventArgs ();
5014 * TileBrush
5016 TileBrush *
5017 tile_brush_new (void)
5019 return new TileBrush ();
5024 * Timeline
5026 DependencyObject *
5027 timeline_get_manual_target (Timeline *instance)
5029 if (instance == NULL)
5030 return NULL;
5032 return instance->GetManualTarget ();
5036 void
5037 timeline_set_manual_target (Timeline *instance, DependencyObject *o)
5039 if (instance == NULL)
5040 return;
5042 instance->SetManualTarget (o);
5046 Timeline *
5047 timeline_new (void)
5049 return new Timeline ();
5054 * TimelineCollection
5056 TimelineCollection *
5057 timeline_collection_new (void)
5059 return new TimelineCollection ();
5064 * TimelineGroup
5066 TimelineGroup *
5067 timeline_group_new (void)
5069 return new TimelineGroup ();
5074 * TimelineMarker
5076 TimelineMarker *
5077 timeline_marker_new (void)
5079 return new TimelineMarker ();
5084 * TimelineMarkerCollection
5086 TimelineMarkerCollection *
5087 timeline_marker_collection_new (void)
5089 return new TimelineMarkerCollection ();
5094 * TimelineMarkerRoutedEventArgs
5096 TimelineMarker *
5097 timeline_marker_routed_event_args_get_marker (TimelineMarkerRoutedEventArgs *instance)
5099 if (instance == NULL)
5100 return NULL;
5102 return instance->GetMarker ();
5106 TimelineMarkerRoutedEventArgs *
5107 timeline_marker_routed_event_args_new (TimelineMarker *marker)
5109 return new TimelineMarkerRoutedEventArgs (marker);
5114 * TimeManager
5116 void
5117 time_manager_add_dispatcher_call (TimeManager *instance, TickCallHandler handler, EventObject *tick_data)
5119 if (instance == NULL)
5120 return;
5122 instance->AddDispatcherCall (handler, tick_data);
5126 void
5127 time_manager_add_tick_call (TimeManager *instance, TickCallHandler handler, EventObject *tick_data)
5129 if (instance == NULL)
5130 return;
5132 instance->AddTickCall (handler, tick_data);
5136 guint
5137 time_manager_add_timeout (TimeManager *instance, gint priority, guint ms_interval, GSourceFunc func, gpointer timeout_data)
5139 if (instance == NULL)
5140 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5141 return (guint) 0;
5143 return instance->AddTimeout (priority, ms_interval, func, timeout_data);
5148 time_manager_get_maximum_refresh_rate (TimeManager *instance)
5150 if (instance == NULL)
5151 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5152 return (int) 0;
5154 return instance->GetMaximumRefreshRate ();
5158 void
5159 time_manager_remove_tick_call (TimeManager *instance, TickCallHandler handler, EventObject *tick_data)
5161 if (instance == NULL)
5162 return;
5164 instance->RemoveTickCall (handler, tick_data);
5168 void
5169 time_manager_remove_timeout (TimeManager *instance, guint timeout_id)
5171 if (instance == NULL)
5172 return;
5174 instance->RemoveTimeout (timeout_id);
5178 void
5179 time_manager_set_maximum_refresh_rate (TimeManager *instance, int hz)
5181 if (instance == NULL)
5182 return;
5184 instance->SetMaximumRefreshRate (hz);
5189 * Transform
5191 Transform *
5192 transform_new (void)
5194 return new Transform ();
5199 * TransformCollection
5201 TransformCollection *
5202 transform_collection_new (void)
5204 return new TransformCollection ();
5209 * TransformGroup
5211 TransformGroup *
5212 transform_group_new (void)
5214 return new TransformGroup ();
5219 * TranslateTransform
5221 TranslateTransform *
5222 translate_transform_new (void)
5224 return new TranslateTransform ();
5229 * TriggerAction
5231 void
5232 trigger_action_fire (TriggerAction *instance)
5234 if (instance == NULL)
5235 return;
5237 instance->Fire ();
5241 TriggerAction *
5242 trigger_action_new (void)
5244 return new TriggerAction ();
5249 * TriggerActionCollection
5251 TriggerActionCollection *
5252 trigger_action_collection_new (void)
5254 return new TriggerActionCollection ();
5259 * TriggerBase
5261 TriggerBase *
5262 trigger_base_new (void)
5264 return new TriggerBase ();
5269 * TriggerCollection
5271 TriggerCollection *
5272 trigger_collection_new (void)
5274 return new TriggerCollection ();
5279 * Types
5281 Type *
5282 types_find (Types *instance, int type)
5284 if (instance == NULL)
5285 return NULL;
5287 return instance->Find ((Type::Kind) type);
5292 types_register_type (Types *instance, const char *name, void *gc_handle, int parent, bool is_interface, bool ctor_visible, int *interfaces, int interface_count)
5294 if (instance == NULL)
5295 return Type::INVALID;
5297 return instance->RegisterType (name, gc_handle, (Type::Kind) parent, is_interface, ctor_visible, (Type::Kind*) interfaces, interface_count);
5301 Types *
5302 types_new (void)
5304 return new Types ();
5309 * UIElement
5311 void
5312 uielement_arrange (UIElement *instance, Rect finalRect)
5314 if (instance == NULL)
5315 return;
5317 instance->Arrange (finalRect);
5321 bool
5322 uielement_capture_mouse (UIElement *instance)
5324 if (instance == NULL)
5325 return false;
5327 return instance->CaptureMouse ();
5331 void
5332 uielement_element_added (UIElement *instance, UIElement *obj)
5334 if (instance == NULL)
5335 return;
5337 instance->ElementAdded (obj);
5341 void
5342 uielement_element_removed (UIElement *instance, UIElement *obj)
5344 if (instance == NULL)
5345 return;
5347 instance->ElementRemoved (obj);
5351 void
5352 uielement_find_elements_in_host_coordinates_p (UIElement *instance, Point p, HitTestCollection *uielement_list)
5354 if (instance == NULL)
5355 return;
5357 instance->FindElementsInHostCoordinates_p (p, uielement_list);
5361 void
5362 uielement_find_elements_in_host_coordinates_r (UIElement *instance, Rect p, HitTestCollection *uielement_list)
5364 if (instance == NULL)
5365 return;
5367 instance->FindElementsInHostCoordinates_r (p, uielement_list);
5371 bool
5372 uielement_focus (UIElement *instance, bool recurse)
5374 if (instance == NULL)
5375 return false;
5377 return instance->Focus (recurse);
5381 Size
5382 uielement_get_desired_size (UIElement *instance)
5384 if (instance == NULL)
5385 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5386 return (Size) 0;
5388 return instance->GetDesiredSize ();
5392 Size
5393 uielement_get_render_size (UIElement *instance)
5395 if (instance == NULL)
5396 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5397 return (Size) 0;
5399 return instance->GetRenderSize ();
5403 DependencyObject *
5404 uielement_get_subtree_object (UIElement *instance)
5406 if (instance == NULL)
5407 return NULL;
5409 return instance->GetSubtreeObject ();
5413 GeneralTransform *
5414 uielement_get_transform_to_uielement_with_error (UIElement *instance, UIElement *to_element, MoonError *error)
5416 if (instance == NULL)
5417 return NULL;
5419 if (error == NULL)
5420 g_warning ("Moonlight: Called uielement_get_transform_to_uielement_with_error () with error == NULL.");
5421 return instance->GetTransformToUIElementWithError (to_element, error);
5425 UIElement *
5426 uielement_get_visual_parent (UIElement *instance)
5428 if (instance == NULL)
5429 return NULL;
5431 return instance->GetVisualParent ();
5435 void
5436 uielement_invalidate (UIElement *instance)
5438 if (instance == NULL)
5439 return;
5441 instance->Invalidate ();
5445 void
5446 uielement_invalidate_arrange (UIElement *instance)
5448 if (instance == NULL)
5449 return;
5451 instance->InvalidateArrange ();
5455 void
5456 uielement_invalidate_measure (UIElement *instance)
5458 if (instance == NULL)
5459 return;
5461 instance->InvalidateMeasure ();
5465 void
5466 uielement_measure (UIElement *instance, Size availableSize)
5468 if (instance == NULL)
5469 return;
5471 instance->Measure (availableSize);
5475 void
5476 uielement_release_mouse_capture (UIElement *instance)
5478 if (instance == NULL)
5479 return;
5481 instance->ReleaseMouseCapture ();
5485 void
5486 uielement_set_subtree_object (UIElement *instance, DependencyObject *value)
5488 if (instance == NULL)
5489 return;
5491 instance->SetSubtreeObject (value);
5495 void
5496 uielement_update_layout (UIElement *instance)
5498 if (instance == NULL)
5499 return;
5501 instance->UpdateLayout ();
5506 * UIElementCollection
5508 UIElementCollection *
5509 uielement_collection_new (void)
5511 return new UIElementCollection ();
5516 * UnmanagedMatrix
5518 UnmanagedMatrix *
5519 unmanaged_matrix_new (void)
5521 return new UnmanagedMatrix ();
5526 * UnmanagedMatrix3D
5528 UnmanagedMatrix3D *
5529 unmanaged_matrix3_d_new (void)
5531 return new UnmanagedMatrix3D ();
5536 * Uri
5538 bool
5539 uri_equals (const Uri *left, const Uri *right)
5541 return Uri::Equals (left, right);
5545 void
5546 uri_free (Uri *instance)
5548 if (instance == NULL)
5549 return;
5551 instance->Free ();
5555 guint
5556 uri_get_hash_code (Uri *instance)
5558 if (instance == NULL)
5559 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5560 return (guint) 0;
5562 return instance->GetHashCode ();
5566 bool
5567 uri_parse (Uri *instance, const char *uri, bool allow_trailing_sep)
5569 if (instance == NULL)
5570 return false;
5572 return instance->Parse (uri, allow_trailing_sep);
5577 * UserControl
5579 UserControl *
5580 user_control_new (void)
5582 return new UserControl ();
5587 * VideoBrush
5589 void
5590 video_brush_set_source (VideoBrush *instance, MediaElement *source)
5592 if (instance == NULL)
5593 return;
5595 instance->SetSource (source);
5599 VideoBrush *
5600 video_brush_new (void)
5602 return new VideoBrush ();
5607 * VideoStream
5609 guint32
5610 video_stream_get_height (VideoStream *instance)
5612 if (instance == NULL)
5613 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5614 return (guint32) 0;
5616 return instance->GetHeight ();
5620 guint32
5621 video_stream_get_width (VideoStream *instance)
5623 if (instance == NULL)
5624 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5625 return (guint32) 0;
5627 return instance->GetWidth ();
5631 VideoStream *
5632 video_stream_new (Media *media, int codec_id, guint32 width, guint32 height, guint64 duration, gpointer extra_data, guint32 extra_data_size)
5634 return new VideoStream (media, codec_id, width, height, duration, extra_data, extra_data_size);
5639 * VisualBrush
5641 VisualBrush *
5642 visual_brush_new (void)
5644 return new VisualBrush ();
5649 * WindowSettings
5651 WindowSettings *
5652 window_settings_new (void)
5654 return new WindowSettings ();
5659 * WriteableBitmap
5661 gpointer
5662 writeable_bitmap_initialize_from_bitmap_source (WriteableBitmap *instance, BitmapSource *source)
5664 if (instance == NULL)
5665 // Need to find a proper way to get the default value for the specified type and return that if instance is NULL.
5666 return (gpointer) 0;
5668 return instance->InitializeFromBitmapSource (source);
5672 void
5673 writeable_bitmap_lock (WriteableBitmap *instance)
5675 if (instance == NULL)
5676 return;
5678 instance->Lock ();
5682 void
5683 writeable_bitmap_render (WriteableBitmap *instance, UIElement *element, Transform *transform)
5685 if (instance == NULL)
5686 return;
5688 instance->Render (element, transform);
5692 void
5693 writeable_bitmap_unlock (WriteableBitmap *instance)
5695 if (instance == NULL)
5696 return;
5698 instance->Unlock ();
5702 WriteableBitmap *
5703 writeable_bitmap_new (void)
5705 return new WriteableBitmap ();
5710 * XamlContext
5712 DependencyObject *
5713 xaml_context_get_template_binding_source (XamlContext *instance)
5715 if (instance == NULL)
5716 return NULL;
5718 return instance->GetTemplateBindingSource ();
5723 * XamlLoader
5725 Value *
5726 xaml_loader_create_from_file_with_error (XamlLoader *instance, const char *xaml, bool create_namescope, int *element_type, MoonError *error)
5728 if (instance == NULL)
5729 return NULL;
5731 if (error == NULL)
5732 g_warning ("Moonlight: Called xaml_loader_create_from_file_with_error () with error == NULL.");
5733 return instance->CreateFromFileWithError (xaml, create_namescope, (Type::Kind*) element_type, error);
5737 Value *
5738 xaml_loader_create_from_string_with_error (XamlLoader *instance, const char *xaml, bool create_namescope, int *element_type, int flags, MoonError *error)
5740 if (instance == NULL)
5741 return NULL;
5743 if (error == NULL)
5744 g_warning ("Moonlight: Called xaml_loader_create_from_string_with_error () with error == NULL.");
5745 return instance->CreateFromStringWithError (xaml, create_namescope, (Type::Kind*) element_type, flags, error);
5749 XamlContext *
5750 xaml_loader_get_context (XamlLoader *instance)
5752 if (instance == NULL)
5753 return NULL;
5755 return instance->GetContext ();
5759 Value *
5760 xaml_loader_hydrate_from_string_with_error (XamlLoader *instance, const char *xaml, Value *obj, bool create_namescope, int *element_type, int flags, MoonError *error)
5762 if (instance == NULL)
5763 return NULL;
5765 if (error == NULL)
5766 g_warning ("Moonlight: Called xaml_loader_hydrate_from_string_with_error () with error == NULL.");
5767 return instance->HydrateFromStringWithError (xaml, obj, create_namescope, (Type::Kind*) element_type, flags, error);
5772 * Xap
5774 char *
5775 xap_unpack (const char *fname)
5777 return Xap::Unpack (fname);