-rw-r--r-- | libopie2/opiecore/device/odevice.h | 7 | ||||
-rw-r--r-- | libopie2/opiecore/device/odevice_htc.cpp | 221 | ||||
-rw-r--r-- | noncore/settings/sysinfo/versioninfo.cpp | 14 | ||||
-rw-r--r-- | pics/sysinfo/htcalpine.png | bin | 0 -> 2743 bytes | |||
-rw-r--r-- | pics/sysinfo/htcapache.png | bin | 0 -> 1863 bytes | |||
-rw-r--r-- | pics/sysinfo/htcbeetles.png | bin | 0 -> 16554 bytes | |||
-rw-r--r-- | pics/sysinfo/htcblueangel.png | bin | 0 -> 4724 bytes | |||
-rw-r--r-- | pics/sysinfo/htchimalaya.png | bin | 0 -> 2743 bytes | |||
-rw-r--r-- | pics/sysinfo/htcmagician.png | bin | 0 -> 3229 bytes | |||
-rw-r--r-- | pics/sysinfo/htcuniversal.png | bin | 0 -> 28617 bytes |
10 files changed, 73 insertions, 169 deletions
diff --git a/libopie2/opiecore/device/odevice.h b/libopie2/opiecore/device/odevice.h index 9afb92d..c2fa411 100644 --- a/libopie2/opiecore/device/odevice.h +++ b/libopie2/opiecore/device/odevice.h @@ -45,115 +45,122 @@ class Sound; namespace Opie{ namespace Core{ class ODeviceData; /** * The available devices */ enum OModel { Model_Unknown, // = 0 Model_Series_Mask = 0xffff0000, Model_iPAQ = ( 1 << 16 ), Model_iPAQ_All = ( Model_iPAQ | 0xffff ), Model_iPAQ_H31xx = ( Model_iPAQ | 0x0001 ), Model_iPAQ_H36xx = ( Model_iPAQ | 0x0002 ), Model_iPAQ_H37xx = ( Model_iPAQ | 0x0003 ), Model_iPAQ_H38xx = ( Model_iPAQ | 0x0004 ), Model_iPAQ_H39xx = ( Model_iPAQ | 0x0005 ), Model_iPAQ_H5xxx = ( Model_iPAQ | 0x0006 ), Model_iPAQ_H22xx = ( Model_iPAQ | 0x0007 ), Model_iPAQ_H191x = ( Model_iPAQ | 0x0008 ), Model_iPAQ_H1940 = ( Model_iPAQ | 0x0009 ), Model_iPAQ_HX4700 = ( Model_iPAQ | 0x000A ), Model_Jornada = ( 6 << 16 ), Model_Jornada_56x = ( Model_Jornada | 0x0001 ), Model_Jornada_720 = ( Model_Jornada | 0x0002 ), + Model_Jornada_820 = ( Model_Jornada | 0x0003 ), Model_Zaurus = ( 2 << 16 ), Model_Zaurus_SL5000 = ( Model_Zaurus | 0x0001 ), Model_Zaurus_SL5500 = ( Model_Zaurus | 0x0002 ), Model_Zaurus_SLA300 = ( Model_Zaurus | 0x0003 ), Model_Zaurus_SLB600 = ( Model_Zaurus | 0x0004 ), Model_Zaurus_SLC7x0 = ( Model_Zaurus | 0x0005 ), Model_Zaurus_SL6000 = ( Model_Zaurus | 0x0006 ), Model_Zaurus_SLC3000 = ( Model_Zaurus | 0x0007 ), Model_Zaurus_SLC1000 = ( Model_Zaurus | 0x0008 ), Model_Zaurus_SLC3100 = ( Model_Zaurus | 0x0009 ), Model_SIMpad = ( 3 << 16 ), Model_SIMpad_All = ( Model_SIMpad | 0xffff ), Model_SIMpad_CL4 = ( Model_SIMpad | 0x0001 ), Model_SIMpad_SL4 = ( Model_SIMpad | 0x0002 ), Model_SIMpad_SLC = ( Model_SIMpad | 0x0003 ), Model_SIMpad_TSinus = ( Model_SIMpad | 0x0004 ), Model_Ramses = ( 4 << 16 ), Model_Ramses_All = ( Model_Ramses | 0xffff ), Model_Ramses_MNCI = ( Model_Ramses | 0x0001 ), Model_Ramses_MNCIRX = ( Model_Ramses | 0x0002 ), Model_Yopy = ( 5 << 16 ), Model_Yopy_All = ( Model_Yopy | 0xffff ), Model_Yopy_3000 = ( Model_Yopy | 0x0001 ), Model_Yopy_3500 = ( Model_Yopy | 0x0002 ), Model_Yopy_3700 = ( Model_Yopy | 0x0003 ), Model_Beagle = ( 6 << 16 ), Model_Beagle_All = ( Model_Beagle | 0xffff ), Model_Beagle_PA100 = ( Model_Beagle | 0x0001 ), Model_GenuineIntel = ( 7 << 16 ), Model_MyPal = ( 8 << 16 ), Model_MyPal_All = ( Model_MyPal | 0xffff ), Model_MyPal_620 = ( Model_MyPal | 0x0001 ), Model_MyPal_716 = ( Model_MyPal | 0x0002 ), Model_MyPal_730 = ( Model_MyPal | 0x0003 ), Model_HTC = ( 9 << 16 ), Model_HTC_All = ( Model_HTC | 0xffff ), Model_HTC_Universal = ( Model_HTC | 0x0001 ), + Model_HTC_Alpine = ( Model_HTC | 0x0002 ), + Model_HTC_Apache = ( Model_HTC | 0x0003 ), + Model_HTC_Beetles = ( Model_HTC | 0x0004 ), + Model_HTC_Blueangel = ( Model_HTC | 0x0005 ), + Model_HTC_Himalaya = ( Model_HTC | 0x0006 ), + Model_HTC_Magician = ( Model_HTC | 0x0007 ), Model_Motorola = ( 9 << 17 ), Model_Motorola_All = ( Model_Motorola | 0xffff ), Model_Motorola_EZX = ( Model_Motorola | 0x0001 ), }; /** * The vendor of the device */ enum OVendor { Vendor_Unknown, Vendor_HP, Vendor_Sharp, Vendor_SIEMENS, Vendor_MundN, Vendor_GMate, Vendor_MasterIA, Vendor_GenuineIntel, Vendor_Asus, Vendor_HTC, Vendor_Motorola, }; /** * The System used */ enum OSystem { System_Unknown, System_Familiar, diff --git a/libopie2/opiecore/device/odevice_htc.cpp b/libopie2/opiecore/device/odevice_htc.cpp index a40308d..c21e10d 100644 --- a/libopie2/opiecore/device/odevice_htc.cpp +++ b/libopie2/opiecore/device/odevice_htc.cpp @@ -87,187 +87,166 @@ struct htc_button htc_buttons_universal [] = { { Qt::Key_F9, QT_TRANSLATE_NOOP("Button", "Calendar Button"), "devicebuttons/z_calendar", "datebook", "nextView()", "today", "raise()" }, { Qt::Key_F10, QT_TRANSLATE_NOOP("Button", "Contacts Button"), "devicebuttons/z_contact", "addressbook", "raise()", "addressbook", "beamBusinessCard()" }, { Qt::Key_F12, QT_TRANSLATE_NOOP("Button", "Home Button"), "devicebuttons/z_home", "QPE/Launcher", "home()", "buttonsettings", "raise()" }, { Qt::Key_F11, QT_TRANSLATE_NOOP("Button", "Menu Button"), "devicebuttons/z_menu", "QPE/TaskBar", "toggleMenu()", "QPE/TaskBar", "toggleStartMenu()" }, { Qt::Key_F13, QT_TRANSLATE_NOOP("Button", "Mail Button"), "devicebuttons/z_mail", "opiemail", "raise()", "opiemail", "newMail()" }, { Qt::Key_F15, QT_TRANSLATE_NOOP("Button", "Hinge1"), "devicebuttons/z_hinge1", "QPE/Rotation", "rotateDefault()",0}, { Qt::Key_F16, QT_TRANSLATE_NOOP("Button", "Hinge2"), "devicebuttons/z_hinge2", "QPE/Rotation", "rotateDefault()",0}, { Qt::Key_F17, QT_TRANSLATE_NOOP("Button", "Hinge3"), "devicebuttons/z_hinge3", "QPE/Rotation", "rotateDefault()",0}, }; -struct htc_button htc_buttons_6000 [] = { - { Qt::Key_F9, QT_TRANSLATE_NOOP("Button", "Calendar Button"), - "devicebuttons/z_calendar", - "datebook", "nextView()", - "today", "raise()" }, - { Qt::Key_F10, QT_TRANSLATE_NOOP("Button", "Contacts Button"), - "devicebuttons/z_contact", - "addressbook", "raise()", - "addressbook", "beamBusinessCard()" }, - { Qt::Key_F12, QT_TRANSLATE_NOOP("Button", "Home Button"), - "devicebuttons/z_home", - "QPE/Launcher", "home()", - "buttonsettings", "raise()" }, - { Qt::Key_F11, QT_TRANSLATE_NOOP("Button", "Menu Button"), - "devicebuttons/z_menu", - "QPE/TaskBar", "toggleMenu()", - "QPE/TaskBar", "toggleStartMenu()" }, - { Qt::Key_F13, QT_TRANSLATE_NOOP("Button", "Mail Button"), - "devicebuttons/z_mail", - "opiemail", "raise()", - "opiemail", "newMail()" }, - { Qt::Key_F15, QT_TRANSLATE_NOOP("Button", "Rotate Button"), - "devicebuttons/z_rotate", - 0, - "QPE/Rotation", "rotateDefault()" }, - { Qt::Key_F24, QT_TRANSLATE_NOOP("Button", "Record Button"), - "devicebuttons/z_hinge3", - "QPE/VMemo", "toggleRecord()", - "sound", "raise()" }, -}; -// FIXME This gets unnecessary complicated. We should think about splitting the HTC -// class up into individual classes. We would need three classes // -// HTC-Universal (PXA-model w/ 640x480 lcd, for Universal) +// HTC-Universal (PXA-model w/ 480x640 3.6" lcd) +// HTC-Alpine (PXA-model w/ 240x320 3.5" lcd) +// HTC-Apache (PXA-model w/ 240x320 2.8" lcd) +// HTC-Beetles (PXA-model w/ 240x240 3.0" lcd) +// HTC-Blueangel (PXA-model w/ 240x320 3.5" lcd) +// HTC-Himalaya (PXA-model w/ 240x320 3.5" lcd) +// HTC-Magician (PXA-model w/ 240x320 2.8" lcd) void HTC::init(const QString& cpu_info) { qDebug( "HTC::init()" ); // Set the time to wait until the system is really suspended // the delta between apm --suspend and sleeping setAPMTimeOut( 15000 ); - // generic distribution code already scanned /etc/issue at that point - - // embedix releases contain "Embedix <version> | Linux for Embedded Devices" - if ( d->m_sysverstr.contains( "embedix", false ) ) - { - d->m_vendorstr = "HTC"; - d->m_vendor = Vendor_HTC; - d->m_systemstr = "OpenEmbedded"; - d->m_system = System_OpenEmbedded; - m_embedix = true; - } - else - { d->m_vendorstr = "Xanadux Team"; d->m_systemstr = "Familiar"; d->m_system = System_Familiar; - // sysver already gathered - - // OpenHTC sometimes uses the 2.4 (embedix) kernel, check if this is one - FILE *uname = popen("uname -r", "r"); - QFile f; - QString line; - if ( f.open(IO_ReadOnly, uname) ) { - QTextStream ts ( &f ); - line = ts.readLine(); - m_embedix = line.startsWith( "2.4." ); - f.close(); - } - pclose(uname); - } // check the HTC model QString model; int loc = cpu_info.find( ":" ); if ( loc != -1 ) model = cpu_info.mid( loc+2 ).simplifyWhiteSpace(); else model = cpu_info; + d->m_model = Model_HTC_Universal; + d->m_modelstr = "Unknown HTC"; + if ( model == "HTC Universal" ) { d->m_model = Model_HTC_Universal; d->m_modelstr = "HTC Universal"; - } else { - d->m_model = Model_HTC_Universal; - d->m_modelstr = "Unknown HTC"; } + if ( model == "HTC Alpine" ) { + d->m_model = Model_HTC_Alpine; + d->m_modelstr = "HTC Alpine"; + } + if ( model == "HTC Apache" ) { + d->m_model = Model_HTC_Apache; + d->m_modelstr = "HTC Apache"; + } + if ( model == "HTC Beetles" ) { + d->m_model = Model_HTC_Beetles; + d->m_modelstr = "HTC Beetles"; + } + if ( model == "HTC Blueangel" ) { + d->m_model = Model_HTC_Blueangel; + d->m_modelstr = "HTC Blueangel"; + } + if ( model == "HTC Himalaya" ) { + d->m_model = Model_HTC_Himalaya; + d->m_modelstr = "HTC Himalaya"; + } + if ( model == "HTC Magician" ) { + d->m_model = Model_HTC_Magician; + d->m_modelstr = "HTC Magician"; + } + - // set path to backlight device in kernel 2.6 + // set path to backlight device switch ( d->m_model ) { case Model_HTC_Universal: + case Model_HTC_Magician: + case Model_HTC_Alpine: + case Model_HTC_Beetles: + case Model_HTC_Apache: + m_backlightdev = "/sys/class/backlight/pxa2xx-fb/"; + break; + case Model_HTC_Blueangel: + case Model_HTC_Himalaya: + m_backlightdev = "/sys/class/backlight/w100fb/"; + break; default: -// m_backlightdev = "/sys/class/backlight/corgi-bl/"; m_backlightdev = "/sys/class/backlight/pxafb/"; } // set initial rotation switch( d->m_model ) { case Model_HTC_Universal: initHingeSensor(); d->m_rotation = rotation(); d->m_direction = direction(); break; default: d->m_rotation = Rot270; } // set default qte driver switch( d->m_model ) { default: d->m_qteDriver = "Transformed"; } m_leds[0] = Led_Off; - if ( m_embedix ) - qDebug( "HTC::init() - Using the 2.4 Embedix HAL on a %s", (const char*) d->m_modelstr ); - else - qDebug( "HTC::init() - Using the 2.6 Xanadux HAL on a %s", (const char*) d->m_modelstr ); + qDebug( "HTC::init() - Using the 2.6 Xanadux on a %s", (const char*) d->m_modelstr ); } void HTC::initButtons() { qDebug( "HTC::initButtons()" ); if ( d->m_buttons ) return; d->m_buttons = new QValueList <ODeviceButton>; struct htc_button * phtc_buttons; int buttoncount; switch ( d->m_model ) { case Model_HTC_Universal: if ( isQWS( ) ) { addPreHandler(this); } phtc_buttons = htc_buttons_universal; buttoncount = ARRAY_SIZE(htc_buttons_universal); break; default: phtc_buttons = htc_buttons; buttoncount = ARRAY_SIZE(htc_buttons); break; } for ( int i = 0; i < buttoncount; i++ ) { struct htc_button *zb = phtc_buttons + i; ODeviceButton b; @@ -349,296 +328,200 @@ void HTC::playTouchSound() void HTC::playKeySound() { buzzer( SHARP_BUZ_KEYSOUND ); } QValueList <OLed> HTC::ledList() const { QValueList <OLed> vl; vl << Led_Mail; return vl; } QValueList <OLedState> HTC::ledStateList( OLed l ) const { QValueList <OLedState> vl; if ( l == Led_Mail ) vl << Led_Off << Led_On << Led_BlinkSlow; return vl; } OLedState HTC::ledState( OLed which ) const { if ( which == Led_Mail ) return m_leds [0]; else return Led_Off; } bool HTC::setLedState( OLed which, OLedState st ) { - // Currently not supported on non_embedix kernels - if (!m_embedix) - { - qDebug( "HTC::setLedState: ODevice handling for non-embedix kernels not yet implemented" ); - return false; - } - - static int fd = ::open ( "/dev/sharp_led", O_RDWR|O_NONBLOCK ); - - if ( which == Led_Mail ) { - if ( fd >= 0 ) { - struct sharp_led_status leds; - ::memset ( &leds, 0, sizeof( leds )); - leds. which = SHARP_LED_MAIL_EXISTS; - bool ok = true; - - switch ( st ) { - case Led_Off : leds. status = LED_MAIL_NO_UNREAD_MAIL; break; - case Led_On : leds. status = LED_MAIL_NEWMAIL_EXISTS; break; - case Led_BlinkSlow: leds. status = LED_MAIL_UNREAD_MAIL_EX; break; - default : ok = false; - } - - if ( ok && ( ::ioctl ( fd, SHARP_LED_SETSTATUS, &leds ) >= 0 )) { - m_leds [0] = st; - return true; - } - } - } + qDebug( "HTC::setLedState: ODevice handling not yet implemented" ); return false; } int HTC::displayBrightnessResolution() const { -/* MV */ - return 16; - int res = 1; - if (m_embedix) - { - int fd = ::open( SHARP_FL_IOCTL_DEVICE, O_RDWR|O_NONBLOCK ); - if ( fd ) - { - int value = ::ioctl( fd, SHARP_FL_IOCTL_GET_STEP, 0 ); - ::close( fd ); - return value ? value : res; - } - } - else - { + int fd = ::open( m_backlightdev + "max_brightness", O_RDONLY|O_NONBLOCK ); + if ( fd ) { char buf[100]; if ( ::read( fd, &buf[0], sizeof buf ) ) ::sscanf( &buf[0], "%d", &res ); ::close( fd ); } - } + return res; } bool HTC::setDisplayBrightness( int bright ) { -/* MV */ - return false; //qDebug( "HTC::setDisplayBrightness( %d )", bright ); bool res = false; if ( bright > 255 ) bright = 255; if ( bright < 0 ) bright = 0; int numberOfSteps = displayBrightnessResolution(); int val = ( bright == 1 ) ? 1 : ( bright * numberOfSteps ) / 255; - if ( m_embedix ) - { - int fd = ::open( SHARP_FL_IOCTL_DEVICE, O_WRONLY|O_NONBLOCK ); - if ( fd ) - { - res = ( ::ioctl( fd, SHARP_FL_IOCTL_STEP_CONTRAST, val ) == 0 ); - ::close( fd ); - } - } - else - { int fd = ::open( m_backlightdev + "brightness", O_WRONLY|O_NONBLOCK ); if ( fd ) { char buf[100]; int len = ::snprintf( &buf[0], sizeof buf, "%d", val ); res = ( ::write( fd, &buf[0], len ) == 0 ); ::close( fd ); } - } return res; } bool HTC::setDisplayStatus( bool on ) { -/* MV */ - return false; bool res = false; - if ( m_embedix ) - { - int fd = ::open( SHARP_FL_IOCTL_DEVICE, O_WRONLY|O_NONBLOCK ); - if ( fd ) - { - int ioctlnum = on ? SHARP_FL_IOCTL_ON : SHARP_FL_IOCTL_OFF; - res = ( ::ioctl ( fd, ioctlnum, 0 ) == 0 ); - ::close ( fd ); - } - } - else - { + int fd = ::open( m_backlightdev + "power", O_WRONLY|O_NONBLOCK ); if ( fd ) { char buf[10]; buf[0] = on ? FB_BLANK_UNBLANK : FB_BLANK_POWERDOWN; buf[1] = '\0'; res = ( ::write( fd, &buf[0], 2 ) == 0 ); ::close( fd ); } - } return res; } Transformation HTC::rotation() const { qDebug( "HTC::rotation()" ); Transformation rot; switch ( d->m_model ) { case Model_HTC_Universal: { OHingeStatus hs = readHingeSensor(); qDebug( "HTC::rotation() - hinge sensor = %d", (int) hs ); if ( hs == CASE_PORTRAIT ) rot = Rot0; else if ( hs == CASE_UNKNOWN ) rot = Rot270; else rot = Rot270; } break; } qDebug( "HTC::rotation() - returning '%d'", rot ); return rot; } ODirection HTC::direction() const { ODirection dir; switch ( d->m_model ) { case Model_HTC_Universal: { OHingeStatus hs = readHingeSensor(); if ( hs == CASE_PORTRAIT ) dir = CCW; else if ( hs == CASE_UNKNOWN ) dir = CCW; else dir = CW; } break; default: dir = d->m_direction; break; } return dir; } bool HTC::hasHingeSensor() const { return d->m_model == Model_HTC_Universal; } OHingeStatus HTC::readHingeSensor() const { - if (m_embedix) - { - int handle = ::open("/dev/apm_bios", O_RDWR|O_NONBLOCK); - if (handle == -1) - { - qWarning("HTC::readHingeSensor() - failed (%s)", "unknown reason" ); //FIXME: use strerror - return CASE_UNKNOWN; - } - else - { - int retval = ::ioctl(handle, SHARP_IOCTL_GET_ROTATION); - ::close (handle); - if ( retval == CASE_CLOSED || retval == CASE_PORTRAIT || retval == CASE_LANDSCAPE ) - { - qDebug( "HTC::readHingeSensor() - result = %d", retval ); - return static_cast<OHingeStatus>( retval ); - } - else - { - qWarning("HTC::readHingeSensor() - couldn't compute hinge status!" ); - return CASE_UNKNOWN; - } - } - } - else - { /* * The HTC Universal keyboard is event source 1 in kernel 2.6. * Hinge status is reported via Input System Switchs 0 and 1 like that: * * ------------------------- * | SW0 | SW1 | CASE | * |-----|-----|-----------| * | 0 0 Unknown | * | 1 0 Portrait | * | 0 1 Closed | * | 1 1 Landscape | * ------------------------- */ OInputDevice* keyboard = OInputSystem::instance()->device( "event1" ); bool switch0 = true; bool switch1 = false; if ( keyboard ) { switch0 = keyboard->isHeld( OInputDevice::Switch0 ); switch1 = keyboard->isHeld( OInputDevice::Switch1 ); } if ( switch0 ) { return switch1 ? CASE_LANDSCAPE : CASE_PORTRAIT; } else { return switch1 ? CASE_CLOSED : CASE_UNKNOWN; } } -} void HTC::initHingeSensor() { if ( m_embedix ) return; m_hinge.setName( "/dev/input/event1" ); if ( !m_hinge.open( IO_ReadOnly ) ) { qWarning( "HTC::init() - Couldn't open /dev/input/event1 for read (%s)", strerror( errno ) ); return; } QSocketNotifier* sn = new QSocketNotifier( m_hinge.handle(), QSocketNotifier::Read, this ); QObject::connect( sn, SIGNAL(activated(int)), this, SLOT(hingeSensorTriggered()) ); qDebug( "HTC::init() - Hinge Sensor Initialization successfully completed" ); } void HTC::hingeSensorTriggered() { qDebug( "HTC::hingeSensorTriggered() - got event" ); struct input_event e; if ( ::read( m_hinge.handle(), &e, sizeof e ) > 0 ) { qDebug( "HTC::hingeSensorTriggered() - event has type %d, code %d, value %d", e.type, e.code, e.value ); if ( e.type != EV_SW ) return; if ( readHingeSensor() != CASE_UNKNOWN ) { qDebug( "HTC::hingeSensorTriggered() - got valid switch event, calling rotateDefault()" ); QCopChannel::send( "QPE/Rotation", "rotateDefault()" ); } } diff --git a/noncore/settings/sysinfo/versioninfo.cpp b/noncore/settings/sysinfo/versioninfo.cpp index 29c9a05..5105b42 100644 --- a/noncore/settings/sysinfo/versioninfo.cpp +++ b/noncore/settings/sysinfo/versioninfo.cpp @@ -109,64 +109,78 @@ VersionInfo::VersionInfo( QWidget *parent, const char *name, WFlags f ) QImage logo2 = Opie::Core::OResource::loadImage( "logo/tux-logo" ); logo2 = logo2.smoothScale( 55, 60 ); QPixmap logo2Pixmap; logo2Pixmap.convertFromImage( logo2 ); linuxLogo->setPixmap( logo2Pixmap ); linuxLogo->setFixedSize( 60, 60 ); hb2->addWidget( linuxLogo, 0, Qt::AlignTop + Qt::AlignLeft ); QLabel *kernelVersion = new QLabel( container ); kernelVersion->setText( kernelVersionString ); hb2->addWidget( kernelVersion, 1, Qt::AlignTop + Qt::AlignLeft ); QHBoxLayout *hb3 = new QHBoxLayout( vb ); hb3->setSpacing( 2 ); QLabel *palmtopLogo3 = new QLabel( container ); OModel model = ODevice::inst()->model(); QString modelPixmap = "sysinfo/"; if ( model == Model_Zaurus_SLC7x0 ) modelPixmap += "zaurusc700"; else if ( model >= Model_Zaurus_SL5000 && model <= Model_Zaurus_SLB600 ) modelPixmap += "zaurus5500"; else if ( model >= Model_iPAQ_H31xx && model <= Model_iPAQ_H5xxx ) modelPixmap += "ipaq3600"; else if ( model >= Model_SIMpad_CL4 && model <= Model_SIMpad_TSinus ) modelPixmap += "simpad"; else if ( model == Model_Jornada_56x ) modelPixmap += "jornada56x"; else if ( model == Model_Jornada_720 ) modelPixmap += "jornada720"; + else if ( model == Model_HTC_Universal ) + modelPixmap += "htcuniversal"; + else if ( model == Model_HTC_Blueangel ) + modelPixmap += "htcblueangel"; + else if ( model == Model_HTC_Apache ) + modelPixmap += "htcapache"; + else if ( model == Model_HTC_Magician ) + modelPixmap += "htcmagician"; + else if ( model == Model_HTC_Himalaya ) + modelPixmap += "htchimalaya"; + else if ( model == Model_HTC_Alpine ) + modelPixmap += "htcalpine"; + else if ( model == Model_HTC_Beetles ) + modelPixmap += "htcbeetles"; else modelPixmap += "pda"; QImage logo3 = Opie::Core::OResource::loadImage( modelPixmap ); int width = logo3.width(); int height = logo3.height(); float aspect = float( height ) / width; logo3 = logo3.smoothScale( 50, 50.0 * aspect ); QPixmap logo3Pixmap; logo3Pixmap.convertFromImage( logo3 ); palmtopLogo3->setPixmap( logo3Pixmap ); palmtopLogo3->setFixedSize( 60, 100 ); hb3->addWidget( palmtopLogo3, 0, Qt::AlignTop + Qt::AlignLeft ); QString systemString = "<qt><b>"; systemString.append( ODevice::inst()->systemString() ); systemString.append( "</b>" ); systemString.append( tr( "<p>Version: " ) ); systemString.append( ODevice::inst()->systemVersionString() ); systemString.append( tr( "<br>Model: " ) ); systemString.append( ODevice::inst()->modelString() ); systemString.append( tr( "<br>Vendor: " ) ); systemString.append( ODevice::inst()->vendorString() ); systemString.append("</qt>"); QLabel *systemVersion = new QLabel( container ); systemVersion->setText( systemString ); hb3->addWidget( systemVersion, 1, Qt::AlignTop + Qt::AlignLeft ); QWhatsThis::add( this, tr( "This page shows the current versions of Opie, the Linux kernel and distribution running on this handheld device." ) ); diff --git a/pics/sysinfo/htcalpine.png b/pics/sysinfo/htcalpine.png Binary files differnew file mode 100644 index 0000000..6a963d9 --- a/dev/null +++ b/pics/sysinfo/htcalpine.png diff --git a/pics/sysinfo/htcapache.png b/pics/sysinfo/htcapache.png Binary files differnew file mode 100644 index 0000000..f11102f --- a/dev/null +++ b/pics/sysinfo/htcapache.png diff --git a/pics/sysinfo/htcbeetles.png b/pics/sysinfo/htcbeetles.png Binary files differnew file mode 100644 index 0000000..5cfa8af --- a/dev/null +++ b/pics/sysinfo/htcbeetles.png diff --git a/pics/sysinfo/htcblueangel.png b/pics/sysinfo/htcblueangel.png Binary files differnew file mode 100644 index 0000000..46c18d3 --- a/dev/null +++ b/pics/sysinfo/htcblueangel.png diff --git a/pics/sysinfo/htchimalaya.png b/pics/sysinfo/htchimalaya.png Binary files differnew file mode 100644 index 0000000..6a963d9 --- a/dev/null +++ b/pics/sysinfo/htchimalaya.png diff --git a/pics/sysinfo/htcmagician.png b/pics/sysinfo/htcmagician.png Binary files differnew file mode 100644 index 0000000..b6e6223 --- a/dev/null +++ b/pics/sysinfo/htcmagician.png diff --git a/pics/sysinfo/htcuniversal.png b/pics/sysinfo/htcuniversal.png Binary files differnew file mode 100644 index 0000000..e413bfb --- a/dev/null +++ b/pics/sysinfo/htcuniversal.png |