tests/auto/qabstractslider/tst_qabstractslider.cpp
branchRCL_3
changeset 7 3f74d0d4af4c
parent 4 3b1da2848fc7
equal deleted inserted replaced
6:dee5afe5301f 7:3f74d0d4af4c
   766                                         << 1                             // single step
   766                                         << 1                             // single step
   767                                         << 100                           // page step
   767                                         << 100                           // page step
   768                                         << true                          // inverted controls
   768                                         << true                          // inverted controls
   769                                         << 20                            // wheel scroll lines
   769                                         << 20                            // wheel scroll lines
   770                                         << false                         // with modifiers
   770                                         << false                         // with modifiers
   771                                         << 1                             // delta
   771                                         << -1                            // delta
   772                                         << int(Qt::Horizontal)           // orientation of slider
   772                                         << int(Qt::Horizontal)           // orientation of slider
   773                                         << int(Qt::Horizontal)           // orientation of wheel
   773                                         << int(Qt::Horizontal)           // orientation of wheel
   774                                         << 30                            // expected position after
   774                                         << 30                            // expected position after
   775                                         << QPoint(1,1);
   775                                         << QPoint(1,1);
   776 
   776 
   777     QTest::newRow("Past end")              << 50                            // initial position
   777     QTest::newRow("Past end")              << 50                            // initial position
       
   778                                         << 0                             // minimum
       
   779                                         << 100                           // maximum
       
   780                                         << 26                            // single step
       
   781                                         << 100                           // page step
       
   782                                         << false                         // inverted controls
       
   783                                         << 1                             // wheel scroll lines
       
   784                                         << false                         // with modifiers
       
   785                                         << -2                            // delta
       
   786                                         << int(Qt::Horizontal)           // orientation of slider
       
   787                                         << int(Qt::Horizontal)           // orientation of wheel
       
   788                                         << 100                           // expected position after
       
   789                                         << QPoint(0,0);
       
   790 
       
   791     QTest::newRow("Past start")            << 50                            // initial position
   778                                         << 0                             // minimum
   792                                         << 0                             // minimum
   779                                         << 100                           // maximum
   793                                         << 100                           // maximum
   780                                         << 26                            // single step
   794                                         << 26                            // single step
   781                                         << 100                           // page step
   795                                         << 100                           // page step
   782                                         << false                         // inverted controls
   796                                         << false                         // inverted controls
   783                                         << 1                             // wheel scroll lines
   797                                         << 1                             // wheel scroll lines
   784                                         << false                         // with modifiers
   798                                         << false                         // with modifiers
   785                                         << 2                             // delta
   799                                         << 2                             // delta
   786                                         << int(Qt::Horizontal)           // orientation of slider
   800                                         << int(Qt::Horizontal)           // orientation of slider
   787                                         << int(Qt::Horizontal)           // orientation of wheel
   801                                         << int(Qt::Horizontal)           // orientation of wheel
   788                                         << 100                           // expected position after
       
   789                                         << QPoint(0,0);
       
   790 
       
   791     QTest::newRow("Past start")            << 50                            // initial position
       
   792                                         << 0                             // minimum
       
   793                                         << 100                           // maximum
       
   794                                         << 26                            // single step
       
   795                                         << 100                           // page step
       
   796                                         << false                         // inverted controls
       
   797                                         << 1                             // wheel scroll lines
       
   798                                         << false                         // with modifiers
       
   799                                         << -2                             // delta
       
   800                                         << int(Qt::Horizontal)           // orientation of slider
       
   801                                         << int(Qt::Horizontal)           // orientation of wheel
       
   802                                         << 0                             // expected position after
   802                                         << 0                             // expected position after
   803                                         << QPoint(0,0);
   803                                         << QPoint(0,0);
   804 
   804 
   805     QTest::newRow("With modifiers")        << 50                            // initial position
   805     QTest::newRow("With modifiers")        << 50                            // initial position
   806                                         << 0                             // minimum
   806                                         << 0                             // minimum
   808                                         << 1                             // single step
   808                                         << 1                             // single step
   809                                         << 40                            // page step
   809                                         << 40                            // page step
   810                                         << false                         // inverted controls
   810                                         << false                         // inverted controls
   811                                         << 20                            // wheel scroll lines
   811                                         << 20                            // wheel scroll lines
   812                                         << true                          // with modifiers
   812                                         << true                          // with modifiers
   813                                         << 1                             // delta
   813                                         << -1                            // delta
   814                                         << int(Qt::Horizontal)           // orientation of slider
   814                                         << int(Qt::Horizontal)           // orientation of slider
   815                                         << int(Qt::Horizontal)           // orientation of wheel
   815                                         << int(Qt::Horizontal)           // orientation of wheel
   816                                         << 90                            // expected position after
   816                                         << 90                            // expected position after
   817                                         << QPoint(0,0);
   817                                         << QPoint(0,0);
   818 
   818