[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdeextragear-3/kdetv/libkdetv
From:       Dirk Ziegelmeier <dziegel () gmx ! de>
Date:       2005-02-16 22:33:07
Message-ID: 20050216223307.7BD281D2F6 () office ! kde ! org
[Download RAW message or body]

CVS commit by dziegel: 

Don't crash if there are no channels but user starts TV card control dialog


  M +7 -3      controlwidgetimpl.cpp   1.5


--- kdeextragear-3/kdetv/libkdetv/controlwidgetimpl.cpp  #1.4:1.5
@@ -49,6 +49,8 @@ ControlWidgetImpl::ControlWidgetImpl(con
       _dev(dev)
 {
+    if(_channel != NULL) {
     _currentChannel->setChecked(channel->hasControls(_dev));
     _allChannels->setChecked(!channel->hasControls(_dev));
+    }
 
     QGridLayout* basicLayout    = new QGridLayout(_basicControls,    controls.count(), 2, 5);
@@ -163,5 +165,7 @@ void ControlWidgetImpl::defaults()
 void ControlWidgetImpl::apply()
 {
+    if(_channel != NULL) {
     _channel->setHasControls(_dev,_currentChannel->isChecked());
+    }
 }
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic