filemanager/src/filemanager/src/fmdriverview.cpp
changeset 37 15bc28c9dd51
parent 16 ada7962b4308
child 46 d58987eac7e8
equal deleted inserted replaced
16:ada7962b4308 37:15bc28c9dd51
    21 #include "fmviewmanager.h"
    21 #include "fmviewmanager.h"
    22 #include "fmcommon.h"
    22 #include "fmcommon.h"
    23 
    23 
    24 #include <QApplication>
    24 #include <QApplication>
    25 
    25 
    26 #include <hbmessagebox.h>
       
    27 #include <hbmenu.h>
    26 #include <hbmenu.h>
    28 #include <hbaction.h>
    27 #include <hbaction.h>
    29 #include <hbtoolbar.h>
    28 #include <hbtoolbar.h>
    30 #include <hbmainwindow.h>
    29 #include <hbmainwindow.h>
    31 #include <hbsearchpanel.h>
    30 #include <hbsearchpanel.h>
    32 
    31 
    33 FmDriverView::FmDriverView() : FmViewBase( EDriverView )
    32 FmDriverView::FmDriverView() : FmViewBase( EDriverView )
    34 {
    33 {
       
    34     FM_LOG( "FmDriverView::FmDriverView" );
    35     initMenu(); 
    35     initMenu(); 
    36     initToolBar();
    36     initToolBar();
    37     initDiskListWidget();
    37     initDiskListWidget();
    38 
    38 
    39     QMetaObject::connectSlotsByName( this );
    39     QMetaObject::connectSlotsByName( this );
    79 
    79 
    80 void FmDriverView::initDiskListWidget()
    80 void FmDriverView::initDiskListWidget()
    81 {
    81 {
    82     mDriverList = new FmDriverListWidget( this );
    82     mDriverList = new FmDriverListWidget( this );
    83     connect( mDriverList, SIGNAL( activated( const QString& ) ),
    83     connect( mDriverList, SIGNAL( activated( const QString& ) ),
    84              this, SLOT( activated( const QString& ) ) );
    84              this, SLOT( activated( const QString& ) ), Qt::QueuedConnection );
    85     
    85     
    86     connect( mDriverList, SIGNAL( startSearch( const QString&,  const QString& ) ),
    86     connect( mDriverList, SIGNAL( startSearch( const QString&,  const QString& ) ),
    87              this, SLOT( startSearch( const QString&, const QString& ) ) );
    87              this, SLOT( startSearch( const QString&, const QString& ) ) );
    88     
    88     
    89     setWidget( mDriverList );
    89     setWidget( mDriverList );
   107 void FmDriverView::activated( const QString& pathName )
   107 void FmDriverView::activated( const QString& pathName )
   108 {
   108 {
   109     FmViewManager::viewManager()->createFileView( pathName );
   109     FmViewManager::viewManager()->createFileView( pathName );
   110 }
   110 }
   111 
   111 
   112 void FmDriverView::refreshModel( const QString &path  )
   112 void FmDriverView::refreshDrive()
   113 {
   113 {
   114     FmLogger::log( QString( "FmDriverView::refreshModel start" ) );
   114     FM_LOG( QString( "FmDriverView::refreshDrive start" ) );
   115     QString logstring = QString( "Refresh Path:" );
   115     mDriverList->refreshDrive();
   116     logstring.append( path );
   116     FM_LOG( QString( "FmDriverView::refreshDrive end" ) );
   117     mDriverList->refreshModel( path );
       
   118     FmLogger::log( QString( "FmDriverView::refreshModel end" ) );
       
   119 }
   117 }
   120 
   118 
   121 void FmDriverView::on_leftAction_triggered()
   119 void FmDriverView::on_leftAction_triggered()
   122 {
   120 {
   123     FmViewManager::viewManager()->createBackupView();
   121     FmViewManager::viewManager()->createBackupView();