1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-21 15:25:17 +03:00

[Horus] Simulator buttons modelized

This commit is contained in:
Bertrand Songis 2015-11-14 21:15:28 +01:00
parent 2f54e85421
commit 07ca8319ad
3 changed files with 24 additions and 13 deletions

View file

@ -12,6 +12,14 @@
<file>images/simulator/Horus/bottom.png</file>
<file>images/simulator/Horus/led.png</file>
<file>images/simulator/Horus/border-right.png</file>
<file>images/simulator/Horus/left_btn1.png</file>
<file>images/simulator/Horus/left_btn2.png</file>
<file>images/simulator/Horus/left_scrnsht.png</file>
<file>images/simulator/Horus/right_btnU.png</file>
<file>images/simulator/Horus/right_btnL.png</file>
<file>images/simulator/Horus/right_btnD.png</file>
<file>images/simulator/Horus/right_btnR.png</file>
<file>images/simulator/Horus/right_ent.png</file>
<file>images/simulator/9X/9xdb.png</file>
<file>images/simulator/9X/9xdl.png</file>
<file>images/simulator/9X/9xdr.png</file>

View file

@ -178,7 +178,7 @@
<property name="minimumSize">
<size>
<width>480</width>
<height>275</height>
<height>272</height>
</size>
</property>
<property name="maximumSize">

View file

@ -16,18 +16,21 @@ SimulatorDialogHorus::SimulatorDialogHorus(QWidget * parent, SimulatorInterface
initUi<Ui::SimulatorDialogHorus>(ui);
polygon.setPoints(6, 68, 83, 28, 45, 51, 32, 83, 32, 105, 45, 68, 83);
ui->rightbuttons->addArea(polygon, Qt::Key_Up, NULL);
polygon.setPoints(6, 74, 90, 114, 51, 127, 80, 127, 106, 114, 130, 74, 90);
ui->rightbuttons->addArea(polygon, Qt::Key_Right, NULL);
polygon.setPoints(6, 68, 98, 28, 137, 51, 151, 83, 151, 105, 137, 68, 98);
ui->rightbuttons->addArea(polygon, Qt::Key_Down, NULL);
polygon.setPoints(6, 80, 90, 20, 51, 7, 80, 7, 106, 20, 130, 80, 90);
ui->rightbuttons->addArea(polygon, Qt::Key_Left, NULL);
ui->rightbuttons->addArea(5, 148, 39, 182, Qt::Key_Print, NULL);
ui->leftbuttons->addArea(25, 60, 71, 81, Qt::Key_PageUp, NULL);
ui->leftbuttons->addArea(25, 117, 71, 139, Qt::Key_Escape, NULL);
polygon.setPoints(23, 72,125, 85,126, 92,129, 98,133, 100,136, 100,141, 99,145, 96,148, 92,149, 87,147, 82,146, 76,145, 69,146, 63,147, 58,148, 54,148, 52,147, 49,144, 48,139, 47,135, 53,130, 63,127, 72,125);
ui->rightbuttons->addArea(polygon, Qt::Key_Up, "Horus/right_btnU.png");
polygon.setPoints(25, 125,163, 129,164, 132,167, 135,171, 136,177, 137,184, 138,189, 138,195, 137,202, 135,207, 134,211, 131,214, 130,216, 125,217, 121,216, 118,214, 115,211, 115,204, 118,195, 118,187, 118,181, 116,176, 116,171, 118,165, 125,163);
ui->rightbuttons->addArea(polygon, Qt::Key_Right, "Horus/right_btnR.png");
polygon.setPoints(20, 64,234, 72,235, 84,234, 91,232, 97,234, 99,237, 101,242, 100,248, 96,250, 92,252, 83,254, 72,255, 64,254, 57,253, 50,249, 48,245, 47,240, 50,235, 55,233, 64,234);
ui->rightbuttons->addArea(polygon, Qt::Key_Down, "Horus/right_btnD.png");
polygon.setPoints(22, 24,163, 29,166, 30,168, 31,171, 31,175, 30,179, 29,187, 29,192, 30,198, 32,204, 32,209, 30,214, 27,216, 22,217, 17,216, 13,208, 10,197, 9,188, 9,178, 12,169, 15,165, 24,162);
ui->rightbuttons->addArea(polygon, Qt::Key_Left, "Horus/right_btnL.png");
polygon.setPoints(21, 72,148, 83,149, 97,155, 106,163, 112,174, 114,187, 114,198, 110,210, 101,221, 89,228, 78,230, 66,230, 53,226, 43,218, 36,208, 32,196, 32,181, 37,168, 47,157, 57,151, 73,148);
ui->rightbuttons->addArea(polygon, Qt::Key_Enter, "Horus/right_ent.png");
polygon.setPoints(26, 25,164, 31,165, 33,167, 35,169, 35,172, 35,174, 34,179, 34,183, 34,190, 34,195, 36,200, 37,204, 38,208, 37,212, 34,216, 29,218, 25,217, 21,215, 18,210, 16,203, 14,194, 14,184, 15,175, 17,169, 21,165, 25,164);
ui->leftbuttons->addArea(polygon, Qt::Key_PageUp, "Horus/left_btn1.png");
polygon.setPoints(27, 60,227, 66,228, 71,229, 75,230, 81,229, 86,228, 89,227, 94,227, 97,229, 100,232, 100, 234, 100,238, 100,241, 99,243, 94,246, 88,248, 81,249, 73,249, 63,248, 56,246, 50,243, 48,240, 47,235, 48,232, 51,228, 56,227, 60,227);
ui->leftbuttons->addArea(polygon, Qt::Key_Escape, "Horus/left_btn2.png");
ui->leftbuttons->addArea(9, 259, 34, 282, Qt::Key_Print, "Horus/left_scrnsht.png");
// install simulator TRACE hook
simulator->installTraceHook(traceCb);