This file is indexed.

/usr/share/gtk-doc/html/clutter/ClutterDragAction.html is in libclutter-1.0-doc 1.16.4-0ubuntu2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

   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
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Clutter Reference Manual: ClutterDragAction</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
<link rel="home" href="index.html" title="Clutter Reference Manual">
<link rel="up" href="ch04.html" title="Actions">
<link rel="prev" href="ClutterClickAction.html" title="ClutterClickAction">
<link rel="next" href="ClutterDropAction.html" title="ClutterDropAction">
<meta name="generator" content="GTK-Doc V1.20 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="10"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span> 
                  <a href="#ClutterDragAction.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span> 
                  <a href="#ClutterDragAction.object-hierarchy" class="shortcut">Object Hierarchy</a></span><span id="nav_properties"> <span class="dim">|</span> 
                  <a href="#ClutterDragAction.properties" class="shortcut">Properties</a></span><span id="nav_signals"> <span class="dim">|</span> 
                  <a href="#ClutterDragAction.signals" class="shortcut">Signals</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="ch04.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="ClutterClickAction.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="ClutterDropAction.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="ClutterDragAction"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="ClutterDragAction.top_of_page"></a>ClutterDragAction</span></h2>
<p>ClutterDragAction — Action enabling dragging on actors</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="ClutterDragAction.functions"></a><h2>Functions</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="ClutterAction.html" title="ClutterAction"><span class="returnvalue">ClutterAction</span></a> *
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-new" title="clutter_drag_action_new ()">clutter_drag_action_new</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-threshold" title="clutter_drag_action_set_drag_threshold ()">clutter_drag_action_set_drag_threshold</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-drag-threshold" title="clutter_drag_action_get_drag_threshold ()">clutter_drag_action_get_drag_threshold</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-handle" title="clutter_drag_action_set_drag_handle ()">clutter_drag_action_set_drag_handle</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="ClutterActor.html" title="ClutterActor"><span class="returnvalue">ClutterActor</span></a> *
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-drag-handle" title="clutter_drag_action_get_drag_handle ()">clutter_drag_action_get_drag_handle</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-axis" title="clutter_drag_action_set_drag_axis ()">clutter_drag_action_set_drag_axis</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis"><span class="returnvalue">ClutterDragAxis</span></a>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-drag-axis" title="clutter_drag_action_get_drag_axis ()">clutter_drag_action_get_drag_axis</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-area" title="clutter_drag_action_set_drag_area ()">clutter_drag_action_set_drag_area</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">gboolean</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-drag-area" title="clutter_drag_action_get_drag_area ()">clutter_drag_action_get_drag_area</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-press-coords" title="clutter_drag_action_get_press_coords ()">clutter_drag_action_get_press_coords</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-motion-coords" title="clutter_drag_action_get_motion_coords ()">clutter_drag_action_get_motion_coords</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.properties"></a><h2>Properties</h2>
<div class="informaltable"><table border="0">
<colgroup>
<col width="150px" class="properties_type">
<col width="300px" class="properties_name">
<col width="200px" class="properties_flags">
</colgroup>
<tbody>
<tr>
<td class="property_type">
<a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> *</td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-area" title="The “drag-area” property">drag-area</a></td>
<td class="property_flags">Read / Write</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-area-set" title="The “drag-area-set” property">drag-area-set</a></td>
<td class="property_flags">Read</td>
</tr>
<tr>
<td class="property_type"><a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis"><span class="type">ClutterDragAxis</span></a></td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-axis" title="The “drag-axis” property">drag-axis</a></td>
<td class="property_flags">Read / Write</td>
</tr>
<tr>
<td class="property_type">
<a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> *</td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-handle" title="The “drag-handle” property">drag-handle</a></td>
<td class="property_flags">Read / Write</td>
</tr>
<tr>
<td class="property_type"><span class="type">gint</span></td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--x-drag-threshold" title="The “x-drag-threshold” property">x-drag-threshold</a></td>
<td class="property_flags">Read / Write</td>
</tr>
<tr>
<td class="property_type"><span class="type">gint</span></td>
<td class="property_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction--y-drag-threshold" title="The “y-drag-threshold” property">y-drag-threshold</a></td>
<td class="property_flags">Read / Write</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.signals"></a><h2>Signals</h2>
<div class="informaltable"><table border="0">
<colgroup>
<col width="150px" class="signals_return">
<col width="300px" class="signals_name">
<col width="200px" class="signals_flags">
</colgroup>
<tbody>
<tr>
<td class="signal_type"><span class="returnvalue">void</span></td>
<td class="signal_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal">drag-begin</a></td>
<td class="signal_flags">Run Last</td>
</tr>
<tr>
<td class="signal_type"><span class="returnvalue">void</span></td>
<td class="signal_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-end" title="The “drag-end” signal">drag-end</a></td>
<td class="signal_flags">Run Last</td>
</tr>
<tr>
<td class="signal_type"><span class="returnvalue">void</span></td>
<td class="signal_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-motion" title="The “drag-motion” signal">drag-motion</a></td>
<td class="signal_flags">Run Last</td>
</tr>
<tr>
<td class="signal_type"><span class="returnvalue">gboolean</span></td>
<td class="signal_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-progress" title="The “drag-progress” signal">drag-progress</a></td>
<td class="signal_flags">Run Last</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="ClutterDragAction.html#ClutterDragAction-struct" title="struct ClutterDragAction">ClutterDragAction</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="ClutterDragAction.html#ClutterDragActionClass" title="struct ClutterDragActionClass">ClutterDragActionClass</a></td>
</tr>
<tr>
<td class="datatype_keyword">enum</td>
<td class="function_name"><a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis">ClutterDragAxis</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="screen">    GObject
    <span class="lineart">╰──</span> GInitiallyUnowned
        <span class="lineart">╰──</span> <a class="link" href="ClutterActorMeta.html" title="ClutterActorMeta">ClutterActorMeta</a>
            <span class="lineart">╰──</span> <a class="link" href="ClutterAction.html" title="ClutterAction">ClutterAction</a>
                <span class="lineart">╰──</span> ClutterDragAction
</pre>
</div>
<div class="refsect1">
<a name="ClutterDragAction.description"></a><h2>Description</h2>
<p><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> is a sub-class of <a class="link" href="ClutterAction.html" title="ClutterAction"><span class="type">ClutterAction</span></a> that implements
all the necessary logic for dragging actors.</p>
<p>The simplest usage of <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> consists in adding it to
a <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> and setting it as reactive; for instance, the following
code:</p>
<div class="informalexample"><pre class="programlisting">
  clutter_actor_add_action (actor, clutter_drag_action_new ());
  clutter_actor_set_reactive (actor, TRUE);
</pre></div>
<p></p>
<p>will automatically result in the actor moving to follow the pointer
whenever the pointer's button is pressed over the actor and moved
across the stage.</p>
<p>The <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will signal the begin and the end of a dragging
through the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> and <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-end" title="The “drag-end” signal"><span class="type">“drag-end”</span></a>
signals, respectively. Each pointer motion during a drag will also result
in the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-motion" title="The “drag-motion” signal"><span class="type">“drag-motion”</span></a> signal to be emitted.</p>
<p>It is also possible to set another <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> as the dragged actor
by calling <a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-handle" title="clutter_drag_action_set_drag_handle ()"><code class="function">clutter_drag_action_set_drag_handle()</code></a> from within a handle
of the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> signal. The drag handle must be
parented and exist between the emission of <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a>
and <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-end" title="The “drag-end” signal"><span class="type">“drag-end”</span></a>.</p>
<div class="example">
<a name="drag-action-example"></a><p class="title"><b>Example 5. A simple draggable actor</b></p>
<div class="example-contents">
<pre class="programlisting">
#include &lt;stdlib.h&gt;
#include &lt;clutter/clutter.h&gt;

static gboolean
on_enter (ClutterActor *actor,
          ClutterEvent *event)
{
  ClutterTransition *t;

  t = clutter_actor_get_transition (actor, "curl");
  if (t == NULL)
    {
      t = clutter_property_transition_new ("@effects.curl.period");
      clutter_timeline_set_duration (CLUTTER_TIMELINE (t), 250);
      clutter_actor_add_transition (actor, "curl", t);
      g_object_unref (t);
    }

  clutter_transition_set_from (t, G_TYPE_DOUBLE, 0.0);
  clutter_transition_set_to (t, G_TYPE_DOUBLE, 0.25);
  clutter_timeline_rewind (CLUTTER_TIMELINE (t));
  clutter_timeline_start (CLUTTER_TIMELINE (t));

  return CLUTTER_EVENT_STOP;
}

static gboolean
on_leave (ClutterActor *actor,
          ClutterEvent *event)
{
  ClutterTransition *t;

  t = clutter_actor_get_transition (actor, "curl");
  if (t == NULL)
    {
      t = clutter_property_transition_new ("@effects.curl.period");
      clutter_timeline_set_duration (CLUTTER_TIMELINE (t), 250);
      clutter_actor_add_transition (actor, "curl", t);
      g_object_unref (t);
    }

  clutter_transition_set_from (t, G_TYPE_DOUBLE, 0.25);
  clutter_transition_set_to (t, G_TYPE_DOUBLE, 0.0);
  clutter_timeline_rewind (CLUTTER_TIMELINE (t));
  clutter_timeline_start (CLUTTER_TIMELINE (t));

  return CLUTTER_EVENT_STOP;
}

static void
on_drag_begin (ClutterDragAction   *action,
               ClutterActor        *actor,
               gfloat               event_x,
               gfloat               event_y,
               ClutterModifierType  modifiers)
{
  gboolean is_copy = (modifiers &amp; CLUTTER_SHIFT_MASK) ? TRUE : FALSE;
  ClutterActor *drag_handle = NULL;
  ClutterTransition *t;

  if (is_copy)
    {
      ClutterActor *stage = clutter_actor_get_stage (actor);

      drag_handle = clutter_actor_new ();
      clutter_actor_set_size (drag_handle, 48, 48);

      clutter_actor_set_background_color (drag_handle, CLUTTER_COLOR_DarkSkyBlue);

      clutter_actor_add_child (stage, drag_handle);
      clutter_actor_set_position (drag_handle, event_x, event_y);
    }
  else
    drag_handle = actor;

  clutter_drag_action_set_drag_handle (action, drag_handle);

  /* fully desaturate the actor */
  t = clutter_actor_get_transition (actor, "disable");
  if (t == NULL)
    {
      t = clutter_property_transition_new ("@effects.disable.factor");
      clutter_timeline_set_duration (CLUTTER_TIMELINE (t), 250);
      clutter_actor_add_transition (actor, "disable", t);
      g_object_unref (t);
    }

  clutter_transition_set_from (t, G_TYPE_DOUBLE, 0.0);
  clutter_transition_set_to (t, G_TYPE_DOUBLE, 1.0);
  clutter_timeline_rewind (CLUTTER_TIMELINE (t));
  clutter_timeline_start (CLUTTER_TIMELINE (t));
}

static void
on_drag_end (ClutterDragAction   *action,
             ClutterActor        *actor,
             gfloat               event_x,
             gfloat               event_y,
             ClutterModifierType  modifiers)
{
  ClutterActor *drag_handle;
  ClutterTransition *t;

  drag_handle = clutter_drag_action_get_drag_handle (action);
  if (actor != drag_handle)
    {
      gfloat real_x, real_y;
      ClutterActor *parent;

      /* if we are dragging a copy we can destroy the copy now
       * and animate the real actor to the drop coordinates,
       * transformed in the parent's coordinate space
       */
      clutter_actor_save_easing_state (drag_handle);
      clutter_actor_set_easing_mode (drag_handle, CLUTTER_LINEAR);
      clutter_actor_set_opacity (drag_handle, 0);
      clutter_actor_restore_easing_state (drag_handle);
      g_signal_connect (drag_handle, "transitions-completed",
                        G_CALLBACK (clutter_actor_destroy),
                        NULL);

      parent = clutter_actor_get_parent (actor);
      clutter_actor_transform_stage_point (parent, event_x, event_y,
                                           &amp;real_x,
                                           &amp;real_y);

      clutter_actor_save_easing_state (actor);
      clutter_actor_set_easing_mode (actor, CLUTTER_EASE_OUT_CUBIC);
      clutter_actor_set_position (actor, real_x, real_y);
      clutter_actor_restore_easing_state (actor);
    }

  t = clutter_actor_get_transition (actor, "disable");
  if (t == NULL)
    {
      t = clutter_property_transition_new ("@effects.disable.factor");
      clutter_timeline_set_duration (CLUTTER_TIMELINE (t), 250);
      clutter_actor_add_transition (actor, "disable", t);
      g_object_unref (t);
    }

  clutter_transition_set_from (t, G_TYPE_DOUBLE, 1.0);
  clutter_transition_set_to (t, G_TYPE_DOUBLE, 0.0);
  clutter_timeline_rewind (CLUTTER_TIMELINE (t));
  clutter_timeline_start (CLUTTER_TIMELINE (t));
}

static ClutterDragAxis
get_drag_axis (const gchar *str)
{
  if (str == NULL || *str == '\0')
    return CLUTTER_DRAG_AXIS_NONE;

  if (*str == 'x' || *str == 'X')
    return CLUTTER_DRAG_X_AXIS;

  if (*str == 'y' || *str == 'Y')
    return CLUTTER_DRAG_Y_AXIS;

  g_warn_if_reached ();

  return CLUTTER_DRAG_AXIS_NONE;
}

static gchar *drag_axis = NULL;
static gint x_drag_threshold = 0;
static gint y_drag_threshold = 0;

static GOptionEntry entries[] = {
  {
    "x-threshold", 'x',
    0,
    G_OPTION_ARG_INT,
    &amp;x_drag_threshold,
    "Set the horizontal drag threshold", "PIXELS"
  },
  {
    "y-threshold", 'y',
    0,
    G_OPTION_ARG_INT,
    &amp;y_drag_threshold,
    "Set the vertical drag threshold", "PIXELS"
  },
  {
    "axis", 'a',
    0,
    G_OPTION_ARG_STRING,
    &amp;drag_axis,
    "Set the drag axis", "AXIS"
  },

  { NULL }
};

int
main (int argc, char *argv[])
{
  ClutterActor *stage, *handle;
  ClutterAction *action;
  GError *error;

  error = NULL;
  if (clutter_init_with_args (&amp;argc, &amp;argv,
                              "test-drag",
                              entries,
                              NULL,
                              &amp;error) != CLUTTER_INIT_SUCCESS)
    {
      g_print ("Unable to run drag-action: %s\n", error-&gt;message);
      g_error_free (error);

      return EXIT_FAILURE;
    }

  stage = clutter_stage_new ();
  clutter_stage_set_title (CLUTTER_STAGE (stage), "Drag Test");
  clutter_actor_set_size (stage, 800, 600);
  g_signal_connect (stage, "destroy", G_CALLBACK (clutter_main_quit), NULL);

  handle = clutter_actor_new ();
  clutter_actor_set_background_color (handle, CLUTTER_COLOR_SkyBlue);
  clutter_actor_set_size (handle, 128, 128);
  clutter_actor_set_position (handle, (800 - 128) / 2, (600 - 128) / 2);
  clutter_actor_set_reactive (handle, TRUE);
  clutter_actor_add_child (stage, handle);
  g_signal_connect (handle, "enter-event", G_CALLBACK (on_enter), NULL);
  g_signal_connect (handle, "leave-event", G_CALLBACK (on_leave), NULL);

  action = clutter_drag_action_new ();
  clutter_drag_action_set_drag_threshold (CLUTTER_DRAG_ACTION (action),
                                          x_drag_threshold,
                                          y_drag_threshold);
  clutter_drag_action_set_drag_axis (CLUTTER_DRAG_ACTION (action),
                                     get_drag_axis (drag_axis));

  g_signal_connect (action, "drag-begin", G_CALLBACK (on_drag_begin), NULL);
  g_signal_connect (action, "drag-end", G_CALLBACK (on_drag_end), NULL);

  clutter_actor_add_action (handle, action);

  clutter_actor_add_effect_with_name (handle, "disable", clutter_desaturate_effect_new (0.0));
  clutter_actor_add_effect_with_name (handle, "curl", clutter_page_turn_effect_new (0.0, 45.0, 12.0));

  clutter_actor_show (stage);

  clutter_main ();

  return EXIT_SUCCESS;
}

  </pre>
<p>The example program above allows dragging the rectangle around
  the stage using a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a>. When pressing the
  <span class="keycap"><strong>Shift</strong></span> key the actor that is going to be dragged is a
  separate rectangle, and when the drag ends, the original rectangle will
  be animated to the final coordinates.</p>
</div>
</div>
<br class="example-break"><p><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> is available since Clutter 1.4</p>
</div>
<div class="refsect1">
<a name="ClutterDragAction.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="clutter-drag-action-new"></a><h3>clutter_drag_action_new ()</h3>
<pre class="programlisting"><a class="link" href="ClutterAction.html" title="ClutterAction"><span class="returnvalue">ClutterAction</span></a> *
clutter_drag_action_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>Creates a new <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> instance</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.2.5"></a><h4>Returns</h4>
<p> the newly created <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p>
<p></p>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-set-drag-threshold"></a><h3>clutter_drag_action_set_drag_threshold ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_set_drag_threshold
                               (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                <em class="parameter"><code><span class="type">gint</span> x_threshold</code></em>,
                                <em class="parameter"><code><span class="type">gint</span> y_threshold</code></em>);</pre>
<p>Sets the horizontal and vertical drag thresholds that must be
cleared by the pointer before <em class="parameter"><code>action</code></em>
 can begin the dragging.</p>
<p>If <em class="parameter"><code>x_threshold</code></em>
 or <em class="parameter"><code>y_threshold</code></em>
 are set to -1 then the default
drag threshold stored in the <a class="link" href="ClutterSettings.html#ClutterSettings--dnd-drag-threshold" title="The “dnd-drag-threshold” property"><span class="type">“dnd-drag-threshold”</span></a>
property of <a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a> will be used.</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.3.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>x_threshold</p></td>
<td class="parameter_description"><p>a distance on the horizontal axis, in pixels, or
-1 to use the default drag threshold from <a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>y_threshold</p></td>
<td class="parameter_description"><p>a distance on the vertical axis, in pixels, or
-1 to use the default drag threshold from <a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-drag-threshold"></a><h3>clutter_drag_action_get_drag_threshold ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_get_drag_threshold
                               (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                <em class="parameter"><code><span class="type">guint</span> *x_threshold</code></em>,
                                <em class="parameter"><code><span class="type">guint</span> *y_threshold</code></em>);</pre>
<p>Retrieves the values set by <a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-threshold" title="clutter_drag_action_set_drag_threshold ()"><code class="function">clutter_drag_action_set_drag_threshold()</code></a>.</p>
<p>If the <a class="link" href="ClutterDragAction.html#ClutterDragAction--x-drag-threshold" title="The “x-drag-threshold” property"><span class="type">“x-drag-threshold”</span></a> property or the
<a class="link" href="ClutterDragAction.html#ClutterDragAction--y-drag-threshold" title="The “y-drag-threshold” property"><span class="type">“y-drag-threshold”</span></a> property have been set to -1 then
this function will return the default drag threshold value as stored
by the <a class="link" href="ClutterSettings.html#ClutterSettings--dnd-drag-threshold" title="The “dnd-drag-threshold” property"><span class="type">“dnd-drag-threshold”</span></a> property of <a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a>.</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.4.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>x_threshold</p></td>
<td class="parameter_description"><p> return location for the horizontal drag
threshold value, in pixels. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>y_threshold</p></td>
<td class="parameter_description"><p> return location for the vertical drag
threshold value, in pixels. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-set-drag-handle"></a><h3>clutter_drag_action_set_drag_handle ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_set_drag_handle (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                     <em class="parameter"><code><a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> *handle</code></em>);</pre>
<p>Sets the actor to be used as the drag handle.</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.5.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>handle</p></td>
<td class="parameter_description"><p> a <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>, or <code class="literal">NULL</code> to unset. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-drag-handle"></a><h3>clutter_drag_action_get_drag_handle ()</h3>
<pre class="programlisting"><a class="link" href="ClutterActor.html" title="ClutterActor"><span class="returnvalue">ClutterActor</span></a> *
clutter_drag_action_get_drag_handle (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>);</pre>
<p>Retrieves the drag handle set by <a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-handle" title="clutter_drag_action_set_drag_handle ()"><code class="function">clutter_drag_action_set_drag_handle()</code></a></p>
<div class="refsect3">
<a name="id-1.5.5.3.9.6.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.5.5.3.9.6.6"></a><h4>Returns</h4>
<p> a <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>, used as the drag
handle, or <code class="literal">NULL</code> if none was set. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-set-drag-axis"></a><h3>clutter_drag_action_set_drag_axis ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_set_drag_axis (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                   <em class="parameter"><code><a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis"><span class="type">ClutterDragAxis</span></a> axis</code></em>);</pre>
<p>Restricts the dragging action to a specific axis</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.7.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>axis</p></td>
<td class="parameter_description"><p>the axis to constraint the dragging to</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-drag-axis"></a><h3>clutter_drag_action_get_drag_axis ()</h3>
<pre class="programlisting"><a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis"><span class="returnvalue">ClutterDragAxis</span></a>
clutter_drag_action_get_drag_axis (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>);</pre>
<p>Retrieves the axis constraint set by <a class="link" href="ClutterDragAction.html#clutter-drag-action-set-drag-axis" title="clutter_drag_action_set_drag_axis ()"><code class="function">clutter_drag_action_set_drag_axis()</code></a></p>
<div class="refsect3">
<a name="id-1.5.5.3.9.8.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.5.5.3.9.8.6"></a><h4>Returns</h4>
<p> the axis constraint</p>
<p></p>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-set-drag-area"></a><h3>clutter_drag_action_set_drag_area ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_set_drag_area (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                   <em class="parameter"><code>const <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> *drag_area</code></em>);</pre>
<p>Sets <em class="parameter"><code>drag_area</code></em>
 to constrain the dragging of the actor associated
with <em class="parameter"><code>action</code></em>
, so that it position is always within <em class="parameter"><code>drag_area</code></em>
, expressed
in parent's coordinates.
If <em class="parameter"><code>drag_area</code></em>
 is <code class="literal">NULL</code>, the actor is not constrained.</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.9.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>drag_area</p></td>
<td class="parameter_description"><p> a <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-drag-area"></a><h3>clutter_drag_action_get_drag_area ()</h3>
<pre class="programlisting"><span class="returnvalue">gboolean</span>
clutter_drag_action_get_drag_area (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                   <em class="parameter"><code><a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> *drag_area</code></em>);</pre>
<p>Retrieves the "drag area" associated with <em class="parameter"><code>action</code></em>
, that
is a <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> that constrains the actor movements,
in parents coordinates.</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.10.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>drag_area</p></td>
<td class="parameter_description"><p> a <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> to be filled. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.5.5.3.9.10.6"></a><h4>Returns</h4>
<p> <code class="literal">TRUE</code> if the actor is actually constrained (and thus
<em class="parameter"><code>drag_area</code></em>
is valid), <code class="literal">FALSE</code> otherwise</p>
<p></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-press-coords"></a><h3>clutter_drag_action_get_press_coords ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_get_press_coords (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                      <em class="parameter"><code><span class="type">gfloat</span> *press_x</code></em>,
                                      <em class="parameter"><code><span class="type">gfloat</span> *press_y</code></em>);</pre>
<p>Retrieves the coordinates, in stage space, of the press event
that started the dragging</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.11.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>press_x</p></td>
<td class="parameter_description"><p> return location for the press event's X coordinate. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>press_y</p></td>
<td class="parameter_description"><p> return location for the press event's Y coordinate. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="clutter-drag-action-get-motion-coords"></a><h3>clutter_drag_action_get_motion_coords ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
clutter_drag_action_get_motion_coords (<em class="parameter"><code><a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action</code></em>,
                                       <em class="parameter"><code><span class="type">gfloat</span> *motion_x</code></em>,
                                       <em class="parameter"><code><span class="type">gfloat</span> *motion_y</code></em>);</pre>
<p>Retrieves the coordinates, in stage space, of the latest motion
event during the dragging</p>
<div class="refsect3">
<a name="id-1.5.5.3.9.12.5"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>a <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a></p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>motion_x</p></td>
<td class="parameter_description"><p> return location for the latest motion
event's X coordinate. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>motion_y</p></td>
<td class="parameter_description"><p> return location for the latest motion
event's Y coordinate. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="ClutterDragAction-struct"></a><h3>struct ClutterDragAction</h3>
<pre class="programlisting">struct ClutterDragAction;</pre>
<p>The <span class="structname">ClutterDragAction</span> structure contains only
private data and should be accessed using the provided API</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragActionClass"></a><h3>struct ClutterDragActionClass</h3>
<pre class="programlisting">struct ClutterDragActionClass {
  void          (* drag_begin)          (ClutterDragAction   *action,
                                         ClutterActor        *actor,
                                         gfloat               event_x,
                                         gfloat               event_y,
                                         ClutterModifierType  modifiers);
  void          (* drag_motion)         (ClutterDragAction   *action,
                                         ClutterActor        *actor,
                                         gfloat               delta_x,
                                         gfloat               delta_y);
  void          (* drag_end)            (ClutterDragAction   *action,
                                         ClutterActor        *actor,
                                         gfloat               event_x,
                                         gfloat               event_y,
                                         ClutterModifierType  modifiers);
  gboolean      (* drag_progress)       (ClutterDragAction   *action,
                                         ClutterActor        *actor,
                                         gfloat               delta_x,
                                         gfloat               delta_y);
};
</pre>
<p>The <span class="structname">ClutterDragActionClass</span> structure contains
only private data</p>
<div class="refsect3">
<a name="id-1.5.5.3.10.3.5"></a><h4>Members</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="300px" class="struct_members_name">
<col class="struct_members_description">
<col width="200px" class="struct_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="struct_member_name"><p><em class="structfield"><code><a name="ClutterDragActionClass.drag-begin"></a>drag_begin</code></em> ()</p></td>
<td class="struct_member_description"><p>class handler of the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> signal</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><em class="structfield"><code><a name="ClutterDragActionClass.drag-motion"></a>drag_motion</code></em> ()</p></td>
<td class="struct_member_description"><p>class handler of the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-motion" title="The “drag-motion” signal"><span class="type">“drag-motion”</span></a> signal</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><em class="structfield"><code><a name="ClutterDragActionClass.drag-end"></a>drag_end</code></em> ()</p></td>
<td class="struct_member_description"><p>class handler of the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-end" title="The “drag-end” signal"><span class="type">“drag-end”</span></a> signal</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><em class="structfield"><code><a name="ClutterDragActionClass.drag-progress"></a>drag_progress</code></em> ()</p></td>
<td class="struct_member_description"><p>class handler of the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-progress" title="The “drag-progress” signal"><span class="type">“drag-progress”</span></a> signal</p></td>
<td class="struct_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAxis"></a><h3>enum ClutterDragAxis</h3>
<p>The axis of the constraint that should be applied on the
dragging action</p>
<div class="refsect3">
<a name="id-1.5.5.3.10.4.4"></a><h4>Members</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="300px" class="enum_members_name">
<col class="enum_members_description">
<col width="200px" class="enum_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="enum_member_name"><p><a name="CLUTTER-DRAG-AXIS-NONE:CAPS"></a>CLUTTER_DRAG_AXIS_NONE</p></td>
<td class="enum_member_description">
<p>No constraint</p>
</td>
<td class="enum_member_annotations"> </td>
</tr>
<tr>
<td class="enum_member_name"><p><a name="CLUTTER-DRAG-X-AXIS:CAPS"></a>CLUTTER_DRAG_X_AXIS</p></td>
<td class="enum_member_description">
<p>Set a constraint on the X axis</p>
</td>
<td class="enum_member_annotations"> </td>
</tr>
<tr>
<td class="enum_member_name"><p><a name="CLUTTER-DRAG-Y-AXIS:CAPS"></a>CLUTTER_DRAG_Y_AXIS</p></td>
<td class="enum_member_description">
<p>Set a constraint on the Y axis</p>
</td>
<td class="enum_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since 1.4</p>
</div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.property-details"></a><h2>Property Details</h2>
<div class="refsect2">
<a name="ClutterDragAction--drag-area"></a><h3>The <code class="literal">“drag-area”</code> property</h3>
<pre class="programlisting">  “drag-area”                <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a> *</pre>
<p>Constains the dragging action (or in particular, the resulting
actor position) to the specified <a class="link" href="clutter-Base-geometric-types.html#ClutterRect" title="struct ClutterRect"><span class="type">ClutterRect</span></a>, in parent's
coordinates.</p>
<p>Flags: Read / Write</p>
<p class="since">Since 1.12</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction--drag-area-set"></a><h3>The <code class="literal">“drag-area-set”</code> property</h3>
<pre class="programlisting">  “drag-area-set”            <span class="type">gboolean</span></pre>
<p>Whether the <a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-area" title="The “drag-area” property"><span class="type">“drag-area”</span></a> property has been set.</p>
<p>Flags: Read</p>
<p>Default value: FALSE</p>
<p class="since">Since 1.12</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction--drag-axis"></a><h3>The <code class="literal">“drag-axis”</code> property</h3>
<pre class="programlisting">  “drag-axis”                <a class="link" href="ClutterDragAction.html#ClutterDragAxis" title="enum ClutterDragAxis"><span class="type">ClutterDragAxis</span></a></pre>
<p>Constraints the dragging action to the specified axis</p>
<p>Flags: Read / Write</p>
<p>Default value: CLUTTER_DRAG_AXIS_NONE</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction--drag-handle"></a><h3>The <code class="literal">“drag-handle”</code> property</h3>
<pre class="programlisting">  “drag-handle”              <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> *</pre>
<p>The <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> that is effectively being dragged</p>
<p>A <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will, be default, use the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> that
has been attached to the action; it is possible to create a
separate <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> and use it instead.</p>
<p>Setting this property has no effect on the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> argument
passed to the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> signals</p>
<p>Flags: Read / Write</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction--x-drag-threshold"></a><h3>The <code class="literal">“x-drag-threshold”</code> property</h3>
<pre class="programlisting">  “x-drag-threshold”         <span class="type">gint</span></pre>
<p>The horizontal threshold, in pixels, that the cursor must travel
in order to begin a drag action.</p>
<p>When set to a positive value, <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will only emit
<a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> if the pointer has moved
horizontally at least of the given amount of pixels since
the button press event.</p>
<p>When set to -1, <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will use the default threshold
stored in the <a class="link" href="ClutterSettings.html#ClutterSettings--dnd-drag-threshold" title="The “dnd-drag-threshold” property"><span class="type">“dnd-drag-threshold”</span></a> property of
<a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a>.</p>
<p>When read, this property will always return a valid drag
threshold, either as set or the default one.</p>
<p>Flags: Read / Write</p>
<p>Allowed values: &gt;= -1</p>
<p>Default value: 0</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction--y-drag-threshold"></a><h3>The <code class="literal">“y-drag-threshold”</code> property</h3>
<pre class="programlisting">  “y-drag-threshold”         <span class="type">gint</span></pre>
<p>The vertical threshold, in pixels, that the cursor must travel
in order to begin a drag action.</p>
<p>When set to a positive value, <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will only emit
<a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> if the pointer has moved
vertically at least of the given amount of pixels since
the button press event.</p>
<p>When set to -1, <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> will use the value stored
in the <a class="link" href="ClutterSettings.html#ClutterSettings--dnd-drag-threshold" title="The “dnd-drag-threshold” property"><span class="type">“dnd-drag-threshold”</span></a> property of
<a class="link" href="ClutterSettings.html" title="ClutterSettings"><span class="type">ClutterSettings</span></a>.</p>
<p>When read, this property will always return a valid drag
threshold, either as set or the default one.</p>
<p>Flags: Read / Write</p>
<p>Allowed values: &gt;= -1</p>
<p>Default value: 0</p>
<p class="since">Since 1.4</p>
</div>
</div>
<div class="refsect1">
<a name="ClutterDragAction.signal-details"></a><h2>Signal Details</h2>
<div class="refsect2">
<a name="ClutterDragAction-drag-begin"></a><h3>The <code class="literal">“drag-begin”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
user_function (<a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a>  *action,
               <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>       *actor,
               <span class="type">gfloat</span>              event_x,
               <span class="type">gfloat</span>              event_y,
               <a class="link" href="clutter-Events.html#ClutterModifierType" title="enum ClutterModifierType"><span class="type">ClutterModifierType</span></a> modifiers,
               <span class="type">gpointer</span>            user_data)</pre>
<p>The ::drag-begin signal is emitted when the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a>
starts the dragging</p>
<p>The emission of this signal can be delayed by using the
<a class="link" href="ClutterDragAction.html#ClutterDragAction--x-drag-threshold" title="The “x-drag-threshold” property"><span class="type">“x-drag-threshold”</span></a> and
<a class="link" href="ClutterDragAction.html#ClutterDragAction--y-drag-threshold" title="The “y-drag-threshold” property"><span class="type">“y-drag-threshold”</span></a> properties</p>
<div class="refsect3">
<a name="id-1.5.5.3.12.2.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> that emitted the signal</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>actor</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> attached to the action</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event_x</p></td>
<td class="parameter_description"><p>the X coordinate (in stage space) of the press event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event_y</p></td>
<td class="parameter_description"><p>the Y coordinate (in stage space) of the press event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>modifiers</p></td>
<td class="parameter_description"><p>the modifiers of the press event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p>Flags: Run Last</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction-drag-end"></a><h3>The <code class="literal">“drag-end”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
user_function (<a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a>  *action,
               <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>       *actor,
               <span class="type">gfloat</span>              event_x,
               <span class="type">gfloat</span>              event_y,
               <a class="link" href="clutter-Events.html#ClutterModifierType" title="enum ClutterModifierType"><span class="type">ClutterModifierType</span></a> modifiers,
               <span class="type">gpointer</span>            user_data)</pre>
<p>The ::drag-end signal is emitted at the end of the dragging,
when the pointer button's is released</p>
<p>This signal is emitted if and only if the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a>
signal has been emitted first</p>
<div class="refsect3">
<a name="id-1.5.5.3.12.3.6"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> that emitted the signal</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>actor</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> attached to the action</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event_x</p></td>
<td class="parameter_description"><p>the X coordinate (in stage space) of the release event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>event_y</p></td>
<td class="parameter_description"><p>the Y coordinate (in stage space) of the release event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>modifiers</p></td>
<td class="parameter_description"><p>the modifiers of the release event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p>Flags: Run Last</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction-drag-motion"></a><h3>The <code class="literal">“drag-motion”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
user_function (<a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action,
               <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>      *actor,
               <span class="type">gfloat</span>             delta_x,
               <span class="type">gfloat</span>             delta_y,
               <span class="type">gpointer</span>           user_data)</pre>
<p>The ::drag-motion signal is emitted for each motion event after
the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> signal has been emitted.</p>
<p>The components of the distance between the press event and the
latest motion event are computed in the actor's coordinate space,
to take into account eventual transformations. If you want the
stage coordinates of the latest motion event you can use
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-motion-coords" title="clutter_drag_action_get_motion_coords ()"><code class="function">clutter_drag_action_get_motion_coords()</code></a>.</p>
<p>The default handler of the signal will call <a class="link" href="ClutterActor.html#clutter-actor-move-by" title="clutter_actor_move_by ()"><code class="function">clutter_actor_move_by()</code></a>
either on <em class="parameter"><code>actor</code></em>
 or, if set, of <a class="link" href="ClutterDragAction.html#ClutterDragAction--drag-handle" title="The “drag-handle” property"><span class="type">“drag-handle”</span></a> using
the <em class="parameter"><code>delta_x</code></em>
 and <em class="parameter"><code>delta_y</code></em>
 components of the dragging motion. If you
want to override the default behaviour, you can connect to the
<a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-progress" title="The “drag-progress” signal"><span class="type">“drag-progress”</span></a> signal and return <code class="literal">FALSE</code> from the
handler.</p>
<div class="refsect3">
<a name="id-1.5.5.3.12.4.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> that emitted the signal</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>actor</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> attached to the action</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>delta_x</p></td>
<td class="parameter_description"><p>the X component of the distance between the press event
that began the dragging and the current position of the pointer,
as of the latest motion event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>delta_y</p></td>
<td class="parameter_description"><p>the Y component of the distance between the press event
that began the dragging and the current position of the pointer,
as of the latest motion event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p>Flags: Run Last</p>
<p class="since">Since 1.4</p>
</div>
<hr>
<div class="refsect2">
<a name="ClutterDragAction-drag-progress"></a><h3>The <code class="literal">“drag-progress”</code> signal</h3>
<pre class="programlisting"><span class="returnvalue">gboolean</span>
user_function (<a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> *action,
               <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a>      *actor,
               <span class="type">gfloat</span>             delta_x,
               <span class="type">gfloat</span>             delta_y,
               <span class="type">gpointer</span>           user_data)</pre>
<p>The ::drag-progress signal is emitted for each motion event after
the <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-begin" title="The “drag-begin” signal"><span class="type">“drag-begin”</span></a> signal has been emitted.</p>
<p>The components of the distance between the press event and the
latest motion event are computed in the actor's coordinate space,
to take into account eventual transformations. If you want the
stage coordinates of the latest motion event you can use
<a class="link" href="ClutterDragAction.html#clutter-drag-action-get-motion-coords" title="clutter_drag_action_get_motion_coords ()"><code class="function">clutter_drag_action_get_motion_coords()</code></a>.</p>
<p>The default handler will emit <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-motion" title="The “drag-motion” signal"><span class="type">“drag-motion”</span></a>,
if <a class="link" href="ClutterDragAction.html#ClutterDragAction-drag-progress" title="The “drag-progress” signal"><span class="type">“drag-progress”</span></a> emission returns <code class="literal">TRUE</code>.</p>
<div class="refsect3">
<a name="id-1.5.5.3.12.5.7"></a><h4>Parameters</h4>
<div class="informaltable"><table width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>action</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterDragAction.html" title="ClutterDragAction"><span class="type">ClutterDragAction</span></a> that emitted the signal</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>actor</p></td>
<td class="parameter_description"><p>the <a class="link" href="ClutterActor.html" title="ClutterActor"><span class="type">ClutterActor</span></a> attached to the action</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>delta_x</p></td>
<td class="parameter_description"><p>the X component of the distance between the press event
that began the dragging and the current position of the pointer,
as of the latest motion event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>delta_y</p></td>
<td class="parameter_description"><p>the Y component of the distance between the press event
that began the dragging and the current position of the pointer,
as of the latest motion event</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>user_data</p></td>
<td class="parameter_description"><p>user data set when the signal handler was connected.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="id-1.5.5.3.12.5.8"></a><h4>Returns</h4>
<p> <code class="literal">TRUE</code> if the drag should continue, and <code class="literal">FALSE</code>
if it should be stopped.</p>
<p></p>
</div>
<p>Flags: Run Last</p>
<p class="since">Since 1.12</p>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.20</div>
</body>
</html>