1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
|
/* WelcomeDialog.c generated by valac 0.40.4, the Vala compiler
* generated from WelcomeDialog.vala, do not modify */
/* Copyright 2016 Software Freedom Conservancy Inc.
* Copyright 2017 Jens Georg <mail@jensge.org>
*
* This software is licensed under the GNU LGPL (version 2.1 or later).
* See the COPYING file in this distribution.
*/
#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <gtk/gtk.h>
#include <glib/gi18n-lib.h>
#include <gdk/gdk.h>
#include <gio/gio.h>
#define TYPE_WELCOME_SERVICE_ENTRY (welcome_service_entry_get_type ())
#define WELCOME_SERVICE_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_WELCOME_SERVICE_ENTRY, WelcomeServiceEntry))
#define IS_WELCOME_SERVICE_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_WELCOME_SERVICE_ENTRY))
#define WELCOME_SERVICE_ENTRY_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TYPE_WELCOME_SERVICE_ENTRY, WelcomeServiceEntryIface))
typedef struct _WelcomeServiceEntry WelcomeServiceEntry;
typedef struct _WelcomeServiceEntryIface WelcomeServiceEntryIface;
#define TYPE_WELCOME_DIALOG (welcome_dialog_get_type ())
#define WELCOME_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_WELCOME_DIALOG, WelcomeDialog))
#define WELCOME_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_WELCOME_DIALOG, WelcomeDialogClass))
#define IS_WELCOME_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_WELCOME_DIALOG))
#define IS_WELCOME_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_WELCOME_DIALOG))
#define WELCOME_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_WELCOME_DIALOG, WelcomeDialogClass))
typedef struct _WelcomeDialog WelcomeDialog;
typedef struct _WelcomeDialogClass WelcomeDialogClass;
typedef struct _WelcomeDialogPrivate WelcomeDialogPrivate;
#define SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST (spit_data_imports_welcome_import_meta_host_get_type ())
#define SPIT_DATA_IMPORTS_WELCOME_IMPORT_META_HOST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST, SpitDataImportsWelcomeImportMetaHost))
#define SPIT_DATA_IMPORTS_WELCOME_IMPORT_META_HOST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST, SpitDataImportsWelcomeImportMetaHostClass))
#define SPIT_DATA_IMPORTS_IS_WELCOME_IMPORT_META_HOST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST))
#define SPIT_DATA_IMPORTS_IS_WELCOME_IMPORT_META_HOST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST))
#define SPIT_DATA_IMPORTS_WELCOME_IMPORT_META_HOST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SPIT_DATA_IMPORTS_TYPE_WELCOME_IMPORT_META_HOST, SpitDataImportsWelcomeImportMetaHostClass))
typedef struct _SpitDataImportsWelcomeImportMetaHost SpitDataImportsWelcomeImportMetaHost;
typedef struct _SpitDataImportsWelcomeImportMetaHostClass SpitDataImportsWelcomeImportMetaHostClass;
enum {
WELCOME_DIALOG_0_PROPERTY,
WELCOME_DIALOG_NUM_PROPERTIES
};
static GParamSpec* welcome_dialog_properties[WELCOME_DIALOG_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
struct _WelcomeServiceEntryIface {
GTypeInterface parent_iface;
gchar* (*get_service_name) (WelcomeServiceEntry* self);
void (*execute) (WelcomeServiceEntry* self);
};
struct _WelcomeDialog {
GtkDialog parent_instance;
WelcomeDialogPrivate * priv;
};
struct _WelcomeDialogClass {
GtkDialogClass parent_class;
};
struct _WelcomeDialogPrivate {
GtkCheckButton* hide_button;
GtkCheckButton* system_pictures_import_check;
GtkCheckButton** external_import_checks;
gint external_import_checks_length1;
gint _external_import_checks_size_;
WelcomeServiceEntry** external_import_entries;
gint external_import_entries_length1;
gint _external_import_entries_size_;
GtkLabel* secondary_text;
GtkLabel* instruction_header;
GtkBox* import_content;
GtkBox* import_action_checkbox_packer;
GtkBox* external_import_action_checkbox_packer;
SpitDataImportsWelcomeImportMetaHost* import_meta_host;
gboolean import_content_already_installed;
gboolean ok_clicked;
};
static gpointer welcome_dialog_parent_class = NULL;
GType welcome_service_entry_get_type (void) G_GNUC_CONST;
gchar* welcome_service_entry_get_service_name (WelcomeServiceEntry* self);
void welcome_service_entry_execute (WelcomeServiceEntry* self);
GType welcome_dialog_get_type (void) G_GNUC_CONST;
GType spit_data_imports_welcome_import_meta_host_get_type (void) G_GNUC_CONST;
#define WELCOME_DIALOG_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_WELCOME_DIALOG, WelcomeDialogPrivate))
WelcomeDialog* welcome_dialog_new (GtkWindow* owner);
WelcomeDialog* welcome_dialog_construct (GType object_type,
GtkWindow* owner);
gint resources_use_header_bar (void);
SpitDataImportsWelcomeImportMetaHost* spit_data_imports_welcome_import_meta_host_new (WelcomeDialog* dialog);
SpitDataImportsWelcomeImportMetaHost* spit_data_imports_welcome_import_meta_host_construct (GType object_type,
WelcomeDialog* dialog);
static gboolean welcome_dialog_is_system_pictures_import_possible (void);
#define RESOURCES_OK_LABEL _ ("_OK")
gchar* get_display_pathname (GFile* file);
GFile* app_dirs_get_import_dir (void);
static void welcome_dialog_install_import_content (WelcomeDialog* self);
void spit_data_imports_welcome_import_meta_host_start (SpitDataImportsWelcomeImportMetaHost* self);
void welcome_dialog_install_service_entry (WelcomeDialog* self,
WelcomeServiceEntry* entry);
static void _vala_array_add4 (WelcomeServiceEntry** * array,
int* length,
int* size,
WelcomeServiceEntry* value);
static void _vala_array_add5 (GtkCheckButton** * array,
int* length,
int* size,
GtkCheckButton* value);
static void welcome_dialog_on_dismiss (WelcomeDialog* self,
gint resp);
gboolean welcome_dialog_execute (WelcomeDialog* self,
WelcomeServiceEntry*** selected_import_entries,
int* selected_import_entries_length1,
gboolean* do_system_pictures_import);
static void _welcome_dialog_on_dismiss_gtk_dialog_response (GtkDialog* _sender,
gint response_id,
gpointer self);
static void _vala_array_add6 (WelcomeServiceEntry** * array,
int* length,
int* size,
WelcomeServiceEntry* value);
static WelcomeServiceEntry** _vala_array_dup1 (WelcomeServiceEntry** self,
int length);
static void welcome_dialog_finalize (GObject * obj);
static void _vala_array_destroy (gpointer array,
gint array_length,
GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
gint array_length,
GDestroyNotify destroy_func);
gchar*
welcome_service_entry_get_service_name (WelcomeServiceEntry* self)
{
#line 9 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_val_if_fail (IS_WELCOME_SERVICE_ENTRY (self), NULL);
#line 9 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return WELCOME_SERVICE_ENTRY_GET_INTERFACE (self)->get_service_name (self);
#line 157 "WelcomeDialog.c"
}
void
welcome_service_entry_execute (WelcomeServiceEntry* self)
{
#line 11 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_if_fail (IS_WELCOME_SERVICE_ENTRY (self));
#line 11 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
WELCOME_SERVICE_ENTRY_GET_INTERFACE (self)->execute (self);
#line 168 "WelcomeDialog.c"
}
static void
welcome_service_entry_base_init (WelcomeServiceEntryIface * iface)
{
#line 8 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
static gboolean initialized = FALSE;
#line 8 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (!initialized) {
#line 8 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
initialized = TRUE;
#line 181 "WelcomeDialog.c"
}
}
GType
welcome_service_entry_get_type (void)
{
static volatile gsize welcome_service_entry_type_id__volatile = 0;
if (g_once_init_enter (&welcome_service_entry_type_id__volatile)) {
static const GTypeInfo g_define_type_info = { sizeof (WelcomeServiceEntryIface), (GBaseInitFunc) welcome_service_entry_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
GType welcome_service_entry_type_id;
welcome_service_entry_type_id = g_type_register_static (G_TYPE_INTERFACE, "WelcomeServiceEntry", &g_define_type_info, 0);
g_type_interface_add_prerequisite (welcome_service_entry_type_id, G_TYPE_OBJECT);
g_once_init_leave (&welcome_service_entry_type_id__volatile, welcome_service_entry_type_id);
}
return welcome_service_entry_type_id__volatile;
}
static gpointer
_g_object_ref0 (gpointer self)
{
#line 32 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return self ? g_object_ref (self) : NULL;
#line 206 "WelcomeDialog.c"
}
WelcomeDialog*
welcome_dialog_construct (GType object_type,
GtkWindow* owner)
{
WelcomeDialog * self = NULL;
SpitDataImportsWelcomeImportMetaHost* _tmp0_;
gboolean show_system_pictures_import = FALSE;
GtkWidget* ok_button = NULL;
GtkWidget* _tmp1_;
GtkWidget* _tmp2_;
GtkLabel* primary_text = NULL;
GtkLabel* _tmp3_;
GtkLabel* _tmp4_;
gchar* _tmp5_;
gchar* _tmp6_;
GtkLabel* _tmp7_;
GtkLabel* _tmp8_;
GtkLabel* _tmp9_;
GtkLabel* _tmp10_;
gchar* _tmp11_;
gchar* _tmp12_;
GtkLabel* _tmp13_;
GtkLabel* _tmp14_;
GtkImage* image = NULL;
GtkImage* _tmp15_;
GtkBox* header_text = NULL;
GtkBox* _tmp16_;
GtkBox* _tmp17_;
GtkLabel* _tmp18_;
GtkBox* _tmp19_;
GtkLabel* _tmp20_;
GtkBox* header_content = NULL;
GtkBox* _tmp21_;
GtkBox* _tmp22_;
GtkImage* _tmp23_;
GtkBox* _tmp24_;
GtkBox* _tmp25_;
GtkLabel* instructions = NULL;
GtkLabel* _tmp26_;
gchar* indent_prefix = NULL;
gchar* _tmp27_;
const gchar* _tmp28_ = NULL;
gchar* arrow_glyph = NULL;
gchar* _tmp29_;
GtkLabel* _tmp30_;
const gchar* _tmp31_;
gchar* _tmp32_;
gchar* _tmp33_;
const gchar* _tmp34_;
gchar* _tmp35_;
gchar* _tmp36_;
gchar* _tmp37_;
gchar* _tmp38_;
const gchar* _tmp39_;
gchar* _tmp40_;
gchar* _tmp41_;
gchar* _tmp42_;
gchar* _tmp43_;
const gchar* _tmp44_;
gchar* _tmp45_;
gchar* _tmp46_;
gchar* _tmp47_;
gchar* _tmp48_;
GtkLabel* _tmp49_;
GtkLabel* _tmp50_;
GtkBox* _tmp51_;
GtkBox* _tmp52_;
GtkBox* _tmp53_;
GtkBox* _tmp54_;
gboolean _tmp55_;
GtkLabel* _tmp66_;
GtkLabel* _tmp67_;
GtkLabel* _tmp68_;
GtkLabel* _tmp69_;
GtkBox* content = NULL;
GtkBox* _tmp70_;
GtkBox* _tmp71_;
GtkBox* _tmp72_;
GtkBox* _tmp73_;
GtkLabel* _tmp74_;
GtkCheckButton* _tmp75_;
GtkCheckButton* _tmp76_;
GtkCheckButton* _tmp77_;
GtkBox* _tmp78_;
GtkWidget* _tmp79_;
SpitDataImportsWelcomeImportMetaHost* _tmp80_;
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_val_if_fail (GTK_IS_WINDOW (owner), NULL);
#line 29 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self = (WelcomeDialog*) g_object_new (object_type, "use-header-bar", resources_use_header_bar (), NULL);
#line 30 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = spit_data_imports_welcome_import_meta_host_new (self);
#line 30 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_meta_host);
#line 30 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->import_meta_host = _tmp0_;
#line 31 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
show_system_pictures_import = welcome_dialog_is_system_pictures_import_possible ();
#line 32 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = gtk_dialog_add_button (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_dialog_get_type (), GtkDialog), RESOURCES_OK_LABEL, (gint) GTK_RESPONSE_CLOSE);
#line 32 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2_ = _g_object_ref0 (_tmp1_);
#line 32 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
ok_button = _tmp2_;
#line 33 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_dialog_set_default_response (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_dialog_get_type (), GtkDialog), (gint) GTK_RESPONSE_CLOSE);
#line 35 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_window_set_title (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_window_get_type (), GtkWindow), _ ("Welcome!"));
#line 36 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_window_set_resizable (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_window_get_type (), GtkWindow), FALSE);
#line 37 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_window_set_type_hint (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_window_get_type (), GtkWindow), GDK_WINDOW_TYPE_HINT_DIALOG);
#line 38 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_window_set_transient_for (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_window_get_type (), GtkWindow), owner);
#line 40 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp3_ = (GtkLabel*) gtk_label_new ("");
#line 40 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp3_);
#line 40 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
primary_text = _tmp3_;
#line 41 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4_ = primary_text;
#line 41 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = g_strdup_printf ("<span size=\"large\" weight=\"bold\">%s</span>", _ ("Welcome to Shotwell!"));
#line 41 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp6_ = _tmp5_;
#line 41 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_markup (_tmp4_, _tmp6_);
#line 41 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp6_);
#line 43 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp7_ = primary_text;
#line 43 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_xalign (_tmp7_, 0.0f);
#line 44 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp8_ = primary_text;
#line 44 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_yalign (_tmp8_, 0.5f);
#line 45 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp9_ = (GtkLabel*) gtk_label_new ("");
#line 45 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp9_);
#line 45 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->secondary_text);
#line 45 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->secondary_text = _tmp9_;
#line 46 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp10_ = self->priv->secondary_text;
#line 46 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp11_ = g_strdup_printf ("<span weight=\"normal\">%s</span>", _ ("To get started, import photos in any of these ways:"));
#line 46 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp12_ = _tmp11_;
#line 46 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_markup (_tmp10_, _tmp12_);
#line 46 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp12_);
#line 48 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp13_ = self->priv->secondary_text;
#line 48 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_xalign (_tmp13_, 0.0f);
#line 49 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp14_ = self->priv->secondary_text;
#line 49 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_yalign (_tmp14_, 0.5f);
#line 50 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp15_ = (GtkImage*) gtk_image_new_from_icon_name ("shotwell", (GtkIconSize) GTK_ICON_SIZE_DIALOG);
#line 50 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp15_);
#line 50 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
image = _tmp15_;
#line 52 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp16_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
#line 52 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp16_);
#line 52 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
header_text = _tmp16_;
#line 53 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp17_ = header_text;
#line 53 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp18_ = primary_text;
#line 53 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (_tmp17_, G_TYPE_CHECK_INSTANCE_CAST (_tmp18_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 5);
#line 54 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp19_ = header_text;
#line 54 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp20_ = self->priv->secondary_text;
#line 54 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (_tmp19_, G_TYPE_CHECK_INSTANCE_CAST (_tmp20_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 0);
#line 56 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp21_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 12);
#line 56 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp21_);
#line 56 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
header_content = _tmp21_;
#line 57 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp22_ = header_content;
#line 57 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp23_ = image;
#line 57 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (_tmp22_, G_TYPE_CHECK_INSTANCE_CAST (_tmp23_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 0);
#line 58 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp24_ = header_content;
#line 58 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp25_ = header_text;
#line 58 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (_tmp24_, G_TYPE_CHECK_INSTANCE_CAST (_tmp25_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 0);
#line 60 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp26_ = (GtkLabel*) gtk_label_new ("");
#line 60 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp26_);
#line 60 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
instructions = _tmp26_;
#line 61 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp27_ = g_strdup (" ");
#line 61 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
indent_prefix = _tmp27_;
#line 63 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (gtk_widget_get_direction (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_widget_get_type (), GtkWidget)) == GTK_TEXT_DIR_RTL) {
#line 63 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp28_ = "◂";
#line 430 "WelcomeDialog.c"
} else {
#line 63 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp28_ = "▸";
#line 434 "WelcomeDialog.c"
}
#line 63 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp29_ = g_strdup (_tmp28_);
#line 63 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
arrow_glyph = _tmp29_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp30_ = instructions;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp31_ = indent_prefix;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp32_ = g_strconcat (_tmp31_, "• %s\n", NULL);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp33_ = _tmp32_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp34_ = indent_prefix;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp35_ = g_strconcat (_tmp34_, "• %s\n", NULL);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp36_ = _tmp35_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp37_ = g_strconcat (_tmp33_, _tmp36_, NULL);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp38_ = _tmp37_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp39_ = indent_prefix;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp40_ = g_strconcat (_tmp39_, "• %s", NULL);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp41_ = _tmp40_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp42_ = g_strconcat (_tmp38_, _tmp41_, NULL);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp43_ = _tmp42_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp44_ = arrow_glyph;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp45_ = g_strdup_printf (_ ("Choose <span weight=\"bold\">File %s Import From Folder</span>"), _tmp44_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp46_ = _tmp45_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp47_ = g_strdup_printf (_tmp43_, _tmp46_, _ ("Drag and drop photos onto the Shotwell window"), _ ("Connect a camera to your computer and import"));
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp48_ = _tmp47_;
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_markup (_tmp30_, _tmp48_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp48_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp46_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp43_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp41_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp38_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp36_);
#line 65 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp33_);
#line 70 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp49_ = instructions;
#line 70 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_xalign (_tmp49_, 0.0f);
#line 71 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp50_ = instructions;
#line 71 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_yalign (_tmp50_, 0.5f);
#line 73 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp51_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
#line 73 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp51_);
#line 73 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_action_checkbox_packer);
#line 73 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->import_action_checkbox_packer = _tmp51_;
#line 75 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp52_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
#line 75 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp52_);
#line 75 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->external_import_action_checkbox_packer);
#line 75 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_action_checkbox_packer = _tmp52_;
#line 76 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp53_ = self->priv->import_action_checkbox_packer;
#line 76 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp54_ = self->priv->external_import_action_checkbox_packer;
#line 76 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp53_, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (_tmp54_, gtk_widget_get_type (), GtkWidget));
#line 78 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp55_ = show_system_pictures_import;
#line 78 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp55_) {
#line 528 "WelcomeDialog.c"
GFile* _tmp56_;
GFile* _tmp57_;
gchar* _tmp58_;
gchar* _tmp59_;
gchar* _tmp60_;
gchar* _tmp61_;
GtkCheckButton* _tmp62_;
GtkBox* _tmp63_;
GtkCheckButton* _tmp64_;
GtkCheckButton* _tmp65_;
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp56_ = app_dirs_get_import_dir ();
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp57_ = _tmp56_;
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp58_ = get_display_pathname (_tmp57_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp59_ = _tmp58_;
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp60_ = g_strdup_printf (_ ("_Import photos from your %s folder"), _tmp59_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp61_ = _tmp60_;
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp62_ = (GtkCheckButton*) gtk_check_button_new_with_mnemonic (_tmp61_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp62_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->system_pictures_import_check);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->system_pictures_import_check = _tmp62_;
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp61_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp59_);
#line 79 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (_tmp57_);
#line 82 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp63_ = self->priv->import_action_checkbox_packer;
#line 82 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp64_ = self->priv->system_pictures_import_check;
#line 82 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp63_, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (_tmp64_, gtk_widget_get_type (), GtkWidget));
#line 83 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp65_ = self->priv->system_pictures_import_check;
#line 83 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_toggle_button_set_active (G_TYPE_CHECK_INSTANCE_CAST (_tmp65_, gtk_toggle_button_get_type (), GtkToggleButton), TRUE);
#line 575 "WelcomeDialog.c"
}
#line 86 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp66_ = (GtkLabel*) gtk_label_new (_ ("You can also import photos in any of these ways:"));
#line 86 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp66_);
#line 86 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->instruction_header);
#line 86 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->instruction_header = _tmp66_;
#line 88 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp67_ = self->priv->instruction_header;
#line 88 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_xalign (_tmp67_, 0.0f);
#line 89 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp68_ = self->priv->instruction_header;
#line 89 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_yalign (_tmp68_, 0.5f);
#line 90 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp69_ = self->priv->instruction_header;
#line 90 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_margin_top (G_TYPE_CHECK_INSTANCE_CAST (_tmp69_, gtk_widget_get_type (), GtkWidget), 20);
#line 92 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp70_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 16);
#line 92 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp70_);
#line 92 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
content = _tmp70_;
#line 93 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp71_ = header_content;
#line 93 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (content, G_TYPE_CHECK_INSTANCE_CAST (_tmp71_, gtk_widget_get_type (), GtkWidget), TRUE, TRUE, (guint) 0);
#line 94 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp72_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 2);
#line 94 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp72_);
#line 94 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_content);
#line 94 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->import_content = _tmp72_;
#line 95 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp73_ = self->priv->import_content;
#line 95 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (_tmp73_, gtk_widget_get_type (), GtkWidget));
#line 96 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp74_ = instructions;
#line 96 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (content, G_TYPE_CHECK_INSTANCE_CAST (_tmp74_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 0);
#line 98 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp75_ = (GtkCheckButton*) gtk_check_button_new_with_mnemonic (_ ("_Don’t show this message again"));
#line 98 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp75_);
#line 98 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->hide_button);
#line 98 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->hide_button = _tmp75_;
#line 99 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp76_ = self->priv->hide_button;
#line 99 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_toggle_button_set_active (G_TYPE_CHECK_INSTANCE_CAST (_tmp76_, gtk_toggle_button_get_type (), GtkToggleButton), TRUE);
#line 100 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp77_ = self->priv->hide_button;
#line 100 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (content, G_TYPE_CHECK_INSTANCE_CAST (_tmp77_, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 6);
#line 101 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_halign (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), GTK_ALIGN_FILL);
#line 102 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_valign (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), GTK_ALIGN_FILL);
#line 103 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_hexpand (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), FALSE);
#line 104 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_vexpand (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), FALSE);
#line 105 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_margin_top (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), 12);
#line 106 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_margin_bottom (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), 0);
#line 107 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_margin_start (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), 12);
#line 108 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_set_margin_end (G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), 12);
#line 110 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp78_ = gtk_dialog_get_content_area (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_dialog_get_type (), GtkDialog));
#line 110 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_box_pack_start (G_TYPE_CHECK_INSTANCE_CAST (_tmp78_, gtk_box_get_type (), GtkBox), G_TYPE_CHECK_INSTANCE_CAST (content, gtk_widget_get_type (), GtkWidget), FALSE, FALSE, (guint) 0);
#line 112 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp79_ = ok_button;
#line 112 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_grab_focus (_tmp79_);
#line 114 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
welcome_dialog_install_import_content (self);
#line 116 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp80_ = self->priv->import_meta_host;
#line 116 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
spit_data_imports_welcome_import_meta_host_start (_tmp80_);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (content);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (arrow_glyph);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (indent_prefix);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (instructions);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (header_content);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (header_text);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (image);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (primary_text);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (ok_button);
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return self;
#line 689 "WelcomeDialog.c"
}
WelcomeDialog*
welcome_dialog_new (GtkWindow* owner)
{
#line 28 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return welcome_dialog_construct (TYPE_WELCOME_DIALOG, owner);
#line 698 "WelcomeDialog.c"
}
static void
welcome_dialog_install_import_content (WelcomeDialog* self)
{
gboolean _tmp0_ = FALSE;
gboolean _tmp1_ = FALSE;
GtkCheckButton** _tmp2_;
gint _tmp2__length1;
#line 119 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_if_fail (IS_WELCOME_DIALOG (self));
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2_ = self->priv->external_import_checks;
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2__length1 = self->priv->external_import_checks_length1;
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp2__length1 > 0) {
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = TRUE;
#line 719 "WelcomeDialog.c"
} else {
GtkCheckButton* _tmp3_;
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp3_ = self->priv->system_pictures_import_check;
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = _tmp3_ != NULL;
#line 726 "WelcomeDialog.c"
}
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp1_) {
#line 730 "WelcomeDialog.c"
gboolean _tmp4_;
#line 122 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4_ = self->priv->import_content_already_installed;
#line 122 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = _tmp4_ == FALSE;
#line 736 "WelcomeDialog.c"
} else {
#line 121 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = FALSE;
#line 740 "WelcomeDialog.c"
}
#line 120 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp0_) {
#line 744 "WelcomeDialog.c"
GtkLabel* _tmp5_;
GtkBox* _tmp6_;
GtkBox* _tmp7_;
GtkBox* _tmp8_;
GtkLabel* _tmp9_;
#line 124 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = self->priv->secondary_text;
#line 124 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_label_set_markup (_tmp5_, "");
#line 125 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp6_ = self->priv->import_content;
#line 125 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp7_ = self->priv->import_action_checkbox_packer;
#line 125 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp6_, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (_tmp7_, gtk_widget_get_type (), GtkWidget));
#line 126 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp8_ = self->priv->import_content;
#line 126 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp9_ = self->priv->instruction_header;
#line 126 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp8_, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (_tmp9_, gtk_widget_get_type (), GtkWidget));
#line 127 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->import_content_already_installed = TRUE;
#line 768 "WelcomeDialog.c"
}
}
static void
_vala_array_add4 (WelcomeServiceEntry** * array,
int* length,
int* size,
WelcomeServiceEntry* value)
{
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if ((*length) == (*size)) {
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*size = (*size) ? (2 * (*size)) : 4;
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*array = g_renew (WelcomeServiceEntry*, *array, (*size) + 1);
#line 785 "WelcomeDialog.c"
}
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[(*length)++] = value;
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[*length] = NULL;
#line 791 "WelcomeDialog.c"
}
static void
_vala_array_add5 (GtkCheckButton** * array,
int* length,
int* size,
GtkCheckButton* value)
{
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if ((*length) == (*size)) {
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*size = (*size) ? (2 * (*size)) : 4;
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*array = g_renew (GtkCheckButton*, *array, (*size) + 1);
#line 807 "WelcomeDialog.c"
}
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[(*length)++] = value;
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[*length] = NULL;
#line 813 "WelcomeDialog.c"
}
void
welcome_dialog_install_service_entry (WelcomeDialog* self,
WelcomeServiceEntry* entry)
{
gchar* _tmp0_;
gchar* _tmp1_;
gchar* _tmp2_;
gchar* _tmp3_;
WelcomeServiceEntry** _tmp4_;
gint _tmp4__length1;
WelcomeServiceEntry* _tmp5_;
GtkCheckButton* entry_check = NULL;
gchar* _tmp6_;
gchar* _tmp7_;
gchar* _tmp8_;
gchar* _tmp9_;
GtkCheckButton* _tmp10_;
GtkCheckButton* _tmp11_;
GtkCheckButton** _tmp12_;
gint _tmp12__length1;
GtkCheckButton* _tmp13_;
GtkBox* _tmp14_;
#line 131 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_if_fail (IS_WELCOME_DIALOG (self));
#line 131 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_if_fail (IS_WELCOME_SERVICE_ENTRY (entry));
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = welcome_service_entry_get_service_name (entry);
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = _tmp0_;
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2_ = g_strdup_printf ("WelcomeDialog: Installing service entry for %s", _tmp1_);
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp3_ = _tmp2_;
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_debug ("WelcomeDialog.vala:132: %s", _tmp3_);
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp3_);
#line 132 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp1_);
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4_ = self->priv->external_import_entries;
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4__length1 = self->priv->external_import_entries_length1;
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = _g_object_ref0 (entry);
#line 133 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_array_add4 (&self->priv->external_import_entries, &self->priv->external_import_entries_length1, &self->priv->_external_import_entries_size_, _tmp5_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp6_ = welcome_service_entry_get_service_name (entry);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp7_ = _tmp6_;
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp8_ = g_strdup_printf (_ ("Import photos from your %s library"), _tmp7_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp9_ = _tmp8_;
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp10_ = (GtkCheckButton*) gtk_check_button_new_with_label (_tmp9_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_object_ref_sink (_tmp10_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp11_ = _tmp10_;
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp9_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_free0 (_tmp7_);
#line 134 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
entry_check = _tmp11_;
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp12_ = self->priv->external_import_checks;
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp12__length1 = self->priv->external_import_checks_length1;
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp13_ = _g_object_ref0 (entry_check);
#line 136 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_array_add5 (&self->priv->external_import_checks, &self->priv->external_import_checks_length1, &self->priv->_external_import_checks_size_, _tmp13_);
#line 137 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_toggle_button_set_active (G_TYPE_CHECK_INSTANCE_CAST (entry_check, gtk_toggle_button_get_type (), GtkToggleButton), TRUE);
#line 138 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp14_ = self->priv->external_import_action_checkbox_packer;
#line 138 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp14_, gtk_container_get_type (), GtkContainer), G_TYPE_CHECK_INSTANCE_CAST (entry_check, gtk_widget_get_type (), GtkWidget));
#line 139 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
welcome_dialog_install_import_content (self);
#line 131 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (entry_check);
#line 903 "WelcomeDialog.c"
}
/**
* Connected to the 'response' signal. This is part of a workaround
* for the fact that run()-ning this dialog can interfere with displaying
* images from a camera; please see #4997 for details.
*/
static void
welcome_dialog_on_dismiss (WelcomeDialog* self,
gint resp)
{
#line 147 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_if_fail (IS_WELCOME_DIALOG (self));
#line 148 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (resp == ((gint) GTK_RESPONSE_CLOSE)) {
#line 149 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->ok_clicked = TRUE;
#line 922 "WelcomeDialog.c"
}
#line 151 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_hide (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_widget_get_type (), GtkWidget));
#line 152 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_main_quit ();
#line 928 "WelcomeDialog.c"
}
static void
_welcome_dialog_on_dismiss_gtk_dialog_response (GtkDialog* _sender,
gint response_id,
gpointer self)
{
#line 158 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
welcome_dialog_on_dismiss ((WelcomeDialog*) self, response_id);
#line 939 "WelcomeDialog.c"
}
static void
_vala_array_add6 (WelcomeServiceEntry** * array,
int* length,
int* size,
WelcomeServiceEntry* value)
{
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if ((*length) == (*size)) {
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*size = (*size) ? (2 * (*size)) : 4;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*array = g_renew (WelcomeServiceEntry*, *array, (*size) + 1);
#line 955 "WelcomeDialog.c"
}
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[(*length)++] = value;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
(*array)[*length] = NULL;
#line 961 "WelcomeDialog.c"
}
static WelcomeServiceEntry**
_vala_array_dup1 (WelcomeServiceEntry** self,
int length)
{
WelcomeServiceEntry** result;
int i;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = g_new0 (WelcomeServiceEntry*, length + 1);
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
for (i = 0; i < length; i++) {
#line 975 "WelcomeDialog.c"
WelcomeServiceEntry* _tmp0_;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = _g_object_ref0 (self[i]);
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result[i] = _tmp0_;
#line 981 "WelcomeDialog.c"
}
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 985 "WelcomeDialog.c"
}
gboolean
welcome_dialog_execute (WelcomeDialog* self,
WelcomeServiceEntry*** selected_import_entries,
int* selected_import_entries_length1,
gboolean* do_system_pictures_import)
{
WelcomeServiceEntry** _vala_selected_import_entries = NULL;
int _vala_selected_import_entries_length1 = 0;
gboolean _vala_do_system_pictures_import = FALSE;
gboolean result = FALSE;
guint _tmp0_;
gboolean ok = FALSE;
gboolean _tmp1_;
gboolean show_dialog = FALSE;
gboolean _tmp2_;
WelcomeServiceEntry** _result_ = NULL;
WelcomeServiceEntry** _tmp4_;
gint _result__length1;
gint __result__size_;
WelcomeServiceEntry** _tmp17_;
gint _tmp17__length1;
WelcomeServiceEntry** _tmp18_;
gint _tmp18__length1;
gboolean _tmp19_ = FALSE;
GtkCheckButton* _tmp20_;
#line 155 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_return_val_if_fail (IS_WELCOME_DIALOG (self), FALSE);
#line 158 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_signal_connect_object (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_dialog_get_type (), GtkDialog), "response", (GCallback) _welcome_dialog_on_dismiss_gtk_dialog_response, self, 0);
#line 159 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_show_all (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_widget_get_type (), GtkWidget));
#line 160 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_show (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_widget_get_type (), GtkWidget));
#line 165 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_main ();
#line 169 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_signal_parse_name ("response", gtk_dialog_get_type (), &_tmp0_, NULL, FALSE);
#line 169 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_signal_handlers_disconnect_matched (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_dialog_get_type (), GtkDialog), G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp0_, 0, NULL, (GCallback) _welcome_dialog_on_dismiss_gtk_dialog_response, self);
#line 171 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = self->priv->ok_clicked;
#line 171 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
ok = _tmp1_;
#line 172 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
show_dialog = TRUE;
#line 174 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2_ = ok;
#line 174 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp2_) {
#line 1038 "WelcomeDialog.c"
GtkCheckButton* _tmp3_;
#line 175 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp3_ = self->priv->hide_button;
#line 175 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
show_dialog = !gtk_toggle_button_get_active (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, gtk_toggle_button_get_type (), GtkToggleButton));
#line 1044 "WelcomeDialog.c"
}
#line 178 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4_ = g_new0 (WelcomeServiceEntry*, 0 + 1);
#line 178 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_result_ = _tmp4_;
#line 178 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_result__length1 = 0;
#line 178 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
__result__size_ = _result__length1;
#line 1054 "WelcomeDialog.c"
{
gint i = 0;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
i = 0;
#line 1059 "WelcomeDialog.c"
{
gboolean _tmp5_ = FALSE;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = TRUE;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
while (TRUE) {
#line 1066 "WelcomeDialog.c"
gint _tmp7_;
WelcomeServiceEntry** _tmp8_;
gint _tmp8__length1;
GtkCheckButton** _tmp9_;
gint _tmp9__length1;
gint _tmp10_;
GtkCheckButton* _tmp11_;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (!_tmp5_) {
#line 1076 "WelcomeDialog.c"
gint _tmp6_;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp6_ = i;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
i = _tmp6_ + 1;
#line 1082 "WelcomeDialog.c"
}
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = FALSE;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp7_ = i;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp8_ = self->priv->external_import_entries;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp8__length1 = self->priv->external_import_entries_length1;
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (!(_tmp7_ < _tmp8__length1)) {
#line 179 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
break;
#line 1096 "WelcomeDialog.c"
}
#line 180 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp9_ = self->priv->external_import_checks;
#line 180 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp9__length1 = self->priv->external_import_checks_length1;
#line 180 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp10_ = i;
#line 180 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp11_ = _tmp9_[_tmp10_];
#line 180 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (gtk_toggle_button_get_active (G_TYPE_CHECK_INSTANCE_CAST (_tmp11_, gtk_toggle_button_get_type (), GtkToggleButton)) == TRUE) {
#line 1108 "WelcomeDialog.c"
WelcomeServiceEntry** _tmp12_;
gint _tmp12__length1;
WelcomeServiceEntry** _tmp13_;
gint _tmp13__length1;
gint _tmp14_;
WelcomeServiceEntry* _tmp15_;
WelcomeServiceEntry* _tmp16_;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp12_ = _result_;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp12__length1 = _result__length1;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp13_ = self->priv->external_import_entries;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp13__length1 = self->priv->external_import_entries_length1;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp14_ = i;
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp15_ = _tmp13_[_tmp14_];
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp16_ = _g_object_ref0 (_tmp15_);
#line 181 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_array_add6 (&_result_, &_result__length1, &__result__size_, _tmp16_);
#line 1132 "WelcomeDialog.c"
}
}
}
}
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp17_ = _result_;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp17__length1 = _result__length1;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp18_ = (_tmp17_ != NULL) ? _vala_array_dup1 (_tmp17_, _tmp17__length1) : ((gpointer) _tmp17_);
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp18__length1 = _tmp17__length1;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_selected_import_entries = (_vala_array_free (_vala_selected_import_entries, _vala_selected_import_entries_length1, (GDestroyNotify) g_object_unref), NULL);
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_selected_import_entries = _tmp18_;
#line 183 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_selected_import_entries_length1 = _tmp18__length1;
#line 185 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp20_ = self->priv->system_pictures_import_check;
#line 185 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (_tmp20_ != NULL) {
#line 1155 "WelcomeDialog.c"
GtkCheckButton* _tmp21_;
#line 185 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp21_ = self->priv->system_pictures_import_check;
#line 185 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp19_ = gtk_toggle_button_get_active (G_TYPE_CHECK_INSTANCE_CAST (_tmp21_, gtk_toggle_button_get_type (), GtkToggleButton));
#line 1161 "WelcomeDialog.c"
} else {
#line 185 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp19_ = FALSE;
#line 1165 "WelcomeDialog.c"
}
#line 184 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_do_system_pictures_import = _tmp19_;
#line 187 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
gtk_widget_destroy (G_TYPE_CHECK_INSTANCE_CAST (self, gtk_widget_get_type (), GtkWidget));
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = show_dialog;
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_result_ = (_vala_array_free (_result_, _result__length1, (GDestroyNotify) g_object_unref), NULL);
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (selected_import_entries) {
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*selected_import_entries = _vala_selected_import_entries;
#line 1179 "WelcomeDialog.c"
} else {
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_vala_selected_import_entries = (_vala_array_free (_vala_selected_import_entries, _vala_selected_import_entries_length1, (GDestroyNotify) g_object_unref), NULL);
#line 1183 "WelcomeDialog.c"
}
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (selected_import_entries_length1) {
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*selected_import_entries_length1 = _vala_selected_import_entries_length1;
#line 1189 "WelcomeDialog.c"
}
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (do_system_pictures_import) {
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
*do_system_pictures_import = _vala_do_system_pictures_import;
#line 1195 "WelcomeDialog.c"
}
#line 189 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 1199 "WelcomeDialog.c"
}
static gboolean
welcome_dialog_is_system_pictures_import_possible (void)
{
gboolean result = FALSE;
GFile* system_pictures = NULL;
GFile* _tmp0_;
GFile* _tmp1_;
GFile* _tmp2_;
gboolean _tmp8_ = FALSE;
GError * _inner_error_ = NULL;
#line 193 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = app_dirs_get_import_dir ();
#line 193 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
system_pictures = _tmp0_;
#line 194 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = system_pictures;
#line 194 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (!g_file_query_exists (_tmp1_, NULL)) {
#line 195 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = FALSE;
#line 195 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (system_pictures);
#line 195 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 1227 "WelcomeDialog.c"
}
#line 197 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp2_ = system_pictures;
#line 197 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (!(g_file_query_file_type (_tmp2_, G_FILE_QUERY_INFO_NONE, NULL) == G_FILE_TYPE_DIRECTORY)) {
#line 198 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = FALSE;
#line 198 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (system_pictures);
#line 198 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 1239 "WelcomeDialog.c"
}
{
GFileEnumerator* syspics_child_enum = NULL;
GFile* _tmp3_;
GFileEnumerator* _tmp4_;
GFileInfo* _tmp5_ = NULL;
GFileEnumerator* _tmp6_;
GFileInfo* _tmp7_;
#line 201 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp3_ = system_pictures;
#line 201 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp4_ = g_file_enumerate_children (_tmp3_, "standard::*", G_FILE_QUERY_INFO_NONE, NULL, &_inner_error_);
#line 201 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
syspics_child_enum = _tmp4_;
#line 201 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1256 "WelcomeDialog.c"
goto __catch24_g_error;
}
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp6_ = syspics_child_enum;
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp7_ = g_file_enumerator_next_file (_tmp6_, NULL, &_inner_error_);
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp5_ = _tmp7_;
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (syspics_child_enum);
#line 1269 "WelcomeDialog.c"
goto __catch24_g_error;
}
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = _tmp5_ != NULL;
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (_tmp5_);
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (syspics_child_enum);
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (system_pictures);
#line 203 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 1282 "WelcomeDialog.c"
}
goto __finally24;
__catch24_g_error:
{
GError* e = NULL;
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
e = _inner_error_;
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_inner_error_ = NULL;
#line 205 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
result = FALSE;
#line 205 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_error_free0 (e);
#line 205 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (system_pictures);
#line 205 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return result;
#line 1300 "WelcomeDialog.c"
}
__finally24:
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (system_pictures);
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_clear_error (&_inner_error_);
#line 200 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
return _tmp8_;
#line 1311 "WelcomeDialog.c"
}
static void
welcome_dialog_class_init (WelcomeDialogClass * klass)
{
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
welcome_dialog_parent_class = g_type_class_peek_parent (klass);
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
g_type_class_add_private (klass, sizeof (WelcomeDialogPrivate));
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
G_OBJECT_CLASS (klass)->finalize = welcome_dialog_finalize;
#line 1324 "WelcomeDialog.c"
}
static void
welcome_dialog_instance_init (WelcomeDialog * self)
{
GtkCheckButton** _tmp0_;
WelcomeServiceEntry** _tmp1_;
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv = WELCOME_DIALOG_GET_PRIVATE (self);
#line 16 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->system_pictures_import_check = NULL;
#line 17 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp0_ = g_new0 (GtkCheckButton*, 0 + 1);
#line 17 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_checks = _tmp0_;
#line 17 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_checks_length1 = 0;
#line 17 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->_external_import_checks_size_ = self->priv->external_import_checks_length1;
#line 18 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_tmp1_ = g_new0 (WelcomeServiceEntry*, 0 + 1);
#line 18 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_entries = _tmp1_;
#line 18 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_entries_length1 = 0;
#line 18 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->_external_import_entries_size_ = self->priv->external_import_entries_length1;
#line 25 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->import_content_already_installed = FALSE;
#line 26 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->ok_clicked = FALSE;
#line 1357 "WelcomeDialog.c"
}
static void
welcome_dialog_finalize (GObject * obj)
{
WelcomeDialog * self;
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_WELCOME_DIALOG, WelcomeDialog);
#line 15 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->hide_button);
#line 16 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->system_pictures_import_check);
#line 17 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_checks = (_vala_array_free (self->priv->external_import_checks, self->priv->external_import_checks_length1, (GDestroyNotify) g_object_unref), NULL);
#line 18 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
self->priv->external_import_entries = (_vala_array_free (self->priv->external_import_entries, self->priv->external_import_entries_length1, (GDestroyNotify) g_object_unref), NULL);
#line 19 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->secondary_text);
#line 20 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->instruction_header);
#line 21 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_content);
#line 22 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_action_checkbox_packer);
#line 23 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->external_import_action_checkbox_packer);
#line 24 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
_g_object_unref0 (self->priv->import_meta_host);
#line 14 "/home/jens/Source/shotwell/src/dialogs/WelcomeDialog.vala"
G_OBJECT_CLASS (welcome_dialog_parent_class)->finalize (obj);
#line 1389 "WelcomeDialog.c"
}
GType
welcome_dialog_get_type (void)
{
static volatile gsize welcome_dialog_type_id__volatile = 0;
if (g_once_init_enter (&welcome_dialog_type_id__volatile)) {
static const GTypeInfo g_define_type_info = { sizeof (WelcomeDialogClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) welcome_dialog_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (WelcomeDialog), 0, (GInstanceInitFunc) welcome_dialog_instance_init, NULL };
GType welcome_dialog_type_id;
welcome_dialog_type_id = g_type_register_static (gtk_dialog_get_type (), "WelcomeDialog", &g_define_type_info, 0);
g_once_init_leave (&welcome_dialog_type_id__volatile, welcome_dialog_type_id);
}
return welcome_dialog_type_id__volatile;
}
static void
_vala_array_destroy (gpointer array,
gint array_length,
GDestroyNotify destroy_func)
{
if ((array != NULL) && (destroy_func != NULL)) {
int i;
for (i = 0; i < array_length; i = i + 1) {
if (((gpointer*) array)[i] != NULL) {
destroy_func (((gpointer*) array)[i]);
}
}
}
}
static void
_vala_array_free (gpointer array,
gint array_length,
GDestroyNotify destroy_func)
{
_vala_array_destroy (array, array_length, destroy_func);
g_free (array);
}
|