homescreenapp/hsdomainmodel/src/hsgui.cpp
changeset 55 03646e8da489
parent 51 4785f57bf3d4
child 60 30f14686fb04
--- a/homescreenapp/hsdomainmodel/src/hsgui.cpp	Thu May 27 12:46:08 2010 +0300
+++ b/homescreenapp/hsdomainmodel/src/hsgui.cpp	Fri Jun 11 13:30:16 2010 +0300
@@ -17,6 +17,7 @@
 
 #include <HbInstance>
 #include <HbView>
+
 #include "hsgui.h"
 
 /*!
@@ -27,25 +28,11 @@
 */
 
 /*!
-    Constructor
-*/
-HsGui::HsGui()	
-{    
-}
-
-/*!
-    Destructor.
-*/
-HsGui::~HsGui()
-{
-}
-
-/*!
-    Returns idle view. 
+    Returns the idle view. 
 */
 HbView *HsGui::idleView()
 {
-	return mIdleView.data();    
+    return mIdleView;    
 }
 
 /*!
@@ -55,9 +42,9 @@
 */
 HbView *HsGui::takeIdleView()
 {	
-    HbView *view = mIdleView;
+    HbView *idleView = mIdleView;
     mIdleView = 0;
-    return view;
+    return idleView;
 }
 
 /*!
@@ -67,14 +54,13 @@
 void HsGui::setIdleView(HbView *idleView)
 {
     if (mIdleView != idleView) {
-        HbView *oldView = mIdleView;
+        delete mIdleView;
         mIdleView = idleView;
-        delete oldView;
     }
 }
 
 /*!
-    Return main window.
+    Returns the main window.
 */
 HbMainWindow *HsGui::mainWindow()
 {
@@ -82,6 +68,6 @@
 }
 
 /*!
-    Points to the view instance.
+    Points to the idle view instance.
 */
 QPointer<HbView> HsGui::mIdleView(0);