|
|
|
@ -88,24 +88,24 @@ void InterfaceIcon::updateStatus( int status )
|
|
|
|
|
if ( status == Interface::NOT_AVAILABLE ||
|
|
|
|
|
status == Interface::NOT_EXISTING )
|
|
|
|
|
{
|
|
|
|
|
mTray->setPixmap( mTray->loadIcon( ICON_DISCONNECTED + suffix ) );
|
|
|
|
|
mTray->setPixmap( mTray->loadSizedIcon( ICON_DISCONNECTED + suffix, mTray->width() ) );
|
|
|
|
|
}
|
|
|
|
|
else if ( ( status & Interface::RX_TRAFFIC ) &&
|
|
|
|
|
( status & Interface::TX_TRAFFIC ) )
|
|
|
|
|
{
|
|
|
|
|
mTray->setPixmap( mTray->loadIcon( ICON_TRAFFIC + suffix ) );
|
|
|
|
|
mTray->setPixmap( mTray->loadSizedIcon( ICON_TRAFFIC + suffix, mTray->width() ) );
|
|
|
|
|
}
|
|
|
|
|
else if ( status & Interface::RX_TRAFFIC )
|
|
|
|
|
{
|
|
|
|
|
mTray->setPixmap( mTray->loadIcon( ICON_INCOMING + suffix ) );
|
|
|
|
|
mTray->setPixmap( mTray->loadSizedIcon( ICON_INCOMING + suffix, mTray->width() ) );
|
|
|
|
|
}
|
|
|
|
|
else if ( status & Interface::TX_TRAFFIC )
|
|
|
|
|
{
|
|
|
|
|
mTray->setPixmap( mTray->loadIcon( ICON_OUTGOING + suffix ) );
|
|
|
|
|
mTray->setPixmap( mTray->loadSizedIcon( ICON_OUTGOING + suffix, mTray->width() ) );
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
mTray->setPixmap( mTray->loadIcon( ICON_CONNECTED + suffix ) );
|
|
|
|
|
mTray->setPixmap( mTray->loadSizedIcon( ICON_CONNECTED + suffix, mTray->width() ) );
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -150,6 +150,11 @@ void InterfaceIcon::updateMenu()
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void InterfaceIcon::resizeIcon()
|
|
|
|
|
{
|
|
|
|
|
updateTrayStatus(0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void InterfaceIcon::updateTrayStatus( int previousState )
|
|
|
|
|
{
|
|
|
|
|
bool interfaceExists = mInterface->getData().existing;
|
|
|
|
@ -236,6 +241,8 @@ void InterfaceIcon::updateTrayStatus( int previousState )
|
|
|
|
|
mInterface, SLOT( showSignalPlotter( bool ) ) );
|
|
|
|
|
connect( mTray, SIGNAL( configSelected() ),
|
|
|
|
|
this, SLOT( showConfigDialog() ) );
|
|
|
|
|
connect( mTray, SIGNAL( iconResized() ),
|
|
|
|
|
this, SLOT( resizeIcon() ) );
|
|
|
|
|
|
|
|
|
|
updateStatus( mInterface->getState() );
|
|
|
|
|
updateToolTip();
|
|
|
|
|