author | mickeyl <mickeyl> | 2003-05-23 20:39:17 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-05-23 20:39:17 (UTC) |
commit | 0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e (patch) (unidiff) | |
tree | d3ca4e58beec5121ea2f7c02df1ac689bdb06be3 | |
parent | 165a62b3ca9cc8e2c3c66845f465a38413fa60d9 (diff) | |
download | opie-0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e.zip opie-0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e.tar.gz opie-0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e.tar.bz2 |
fix default rotation and direction for SIMpad
-rw-r--r-- | libopie/odevice.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libopie/odevice.cpp b/libopie/odevice.cpp index 02f13b5..2873407 100644 --- a/libopie/odevice.cpp +++ b/libopie/odevice.cpp | |||
@@ -1484,65 +1484,68 @@ bool Zaurus::setDisplayBrightness ( int bright ) | |||
1484 | } | 1484 | } |
1485 | return res; | 1485 | return res; |
1486 | } | 1486 | } |
1487 | 1487 | ||
1488 | 1488 | ||
1489 | int Zaurus::displayBrightnessResolution ( ) const | 1489 | int Zaurus::displayBrightnessResolution ( ) const |
1490 | { | 1490 | { |
1491 | return 5; | 1491 | return 5; |
1492 | } | 1492 | } |
1493 | 1493 | ||
1494 | 1494 | ||
1495 | /************************************************** | 1495 | /************************************************** |
1496 | * | 1496 | * |
1497 | * SIMpad | 1497 | * SIMpad |
1498 | * | 1498 | * |
1499 | **************************************************/ | 1499 | **************************************************/ |
1500 | 1500 | ||
1501 | void SIMpad::init ( ) | 1501 | void SIMpad::init ( ) |
1502 | { | 1502 | { |
1503 | d-> m_vendorstr = "SIEMENS"; | 1503 | d-> m_vendorstr = "SIEMENS"; |
1504 | d-> m_vendor = Vendor_SIEMENS; | 1504 | d-> m_vendor = Vendor_SIEMENS; |
1505 | 1505 | ||
1506 | QFile f ( "/proc/hal/model" ); | 1506 | QFile f ( "/proc/hal/model" ); |
1507 | 1507 | ||
1508 | //TODO Implement model checking | 1508 | //TODO Implement model checking |
1509 | //FIXME For now we assume an SL4 | 1509 | //FIXME For now we assume an SL4 |
1510 | 1510 | ||
1511 | d-> m_modelstr = "SL4"; | 1511 | d-> m_modelstr = "SL4"; |
1512 | d-> m_model = Model_SIMpad_SL4; | 1512 | d-> m_model = Model_SIMpad_SL4; |
1513 | 1513 | ||
1514 | switch ( d-> m_model ) { | 1514 | switch ( d-> m_model ) { |
1515 | default: | 1515 | default: |
1516 | d-> m_rotation = Rot270; | 1516 | d-> m_rotation = Rot0; |
1517 | d-> m_direction = CCW; | ||
1518 | d-> m_holdtime = 1000; // 1000ms | ||
1519 | |||
1517 | break; | 1520 | break; |
1518 | } | 1521 | } |
1519 | 1522 | ||
1520 | f. setName ( "/etc/familiar-version" ); | 1523 | f. setName ( "/etc/familiar-version" ); |
1521 | if ( f. open ( IO_ReadOnly )) { | 1524 | if ( f. open ( IO_ReadOnly )) { |
1522 | d-> m_systemstr = "Familiar"; | 1525 | d-> m_systemstr = "Familiar"; |
1523 | d-> m_system = System_Familiar; | 1526 | d-> m_system = System_Familiar; |
1524 | 1527 | ||
1525 | QTextStream ts ( &f ); | 1528 | QTextStream ts ( &f ); |
1526 | d-> m_sysverstr = ts. readLine ( ). mid ( 10 ); | 1529 | d-> m_sysverstr = ts. readLine ( ). mid ( 10 ); |
1527 | 1530 | ||
1528 | f. close ( ); | 1531 | f. close ( ); |
1529 | } else { | 1532 | } else { |
1530 | f. setName ( "/etc/oz_version" ); | 1533 | f. setName ( "/etc/oz_version" ); |
1531 | 1534 | ||
1532 | if ( f. open ( IO_ReadOnly )) { | 1535 | if ( f. open ( IO_ReadOnly )) { |
1533 | d-> m_systemstr = "OpenEmbedded/SIMpad"; | 1536 | d-> m_systemstr = "OpenEmbedded/SIMpad"; |
1534 | d-> m_system = System_OpenZaurus; | 1537 | d-> m_system = System_OpenZaurus; |
1535 | 1538 | ||
1536 | QTextStream ts ( &f ); | 1539 | QTextStream ts ( &f ); |
1537 | ts.setDevice ( &f ); | 1540 | ts.setDevice ( &f ); |
1538 | d-> m_sysverstr = ts. readLine ( ); | 1541 | d-> m_sysverstr = ts. readLine ( ); |
1539 | f. close ( ); | 1542 | f. close ( ); |
1540 | } | 1543 | } |
1541 | } | 1544 | } |
1542 | 1545 | ||
1543 | m_leds [0] = m_leds [1] = Led_Off; | 1546 | m_leds [0] = m_leds [1] = Led_Off; |
1544 | 1547 | ||
1545 | m_power_timer = 0; | 1548 | m_power_timer = 0; |
1546 | 1549 | ||
1547 | } | 1550 | } |
1548 | 1551 | ||