Kaydet (Commit) 62f77f52 authored tarafından Szymon Kłos's avatar Szymon Kłos

check if path exist before init of the fileview

Change-Id: I0c9384644cf5aabf83512c341d3ffff5d4847f36
üst d2daae30
......@@ -462,34 +462,41 @@ FileViewResult RemoteFilesDialog::OpenURL( OUString const & sURL )
if( m_pFileView )
{
OUString sFilter = FILEDIALOG_FILTER_ALL;
if( m_nCurrentFilter != LISTBOX_ENTRY_NOTFOUND )
if( ContentIsFolder( sURL ) )
{
sFilter = m_aFilters[m_nCurrentFilter].second;
}
OUString sFilter = FILEDIALOG_FILTER_ALL;
m_pFileView->EndInplaceEditing( false );
if( m_nCurrentFilter != LISTBOX_ENTRY_NOTFOUND )
{
sFilter = m_aFilters[m_nCurrentFilter].second;
}
EnableChildPointerOverwrite( true );
SetPointer( PointerStyle::Wait );
m_pFileView->EndInplaceEditing( false );
eResult = m_pFileView->Initialize( sURL, sFilter, NULL, GetBlackList() );
EnableChildPointerOverwrite( true );
SetPointer( PointerStyle::Wait );
if( eResult == eSuccess )
{
m_pPath->SetURL( sURL );
eResult = m_pFileView->Initialize( sURL, sFilter, NULL, GetBlackList() );
m_pTreeView->SetSelectHdl( Link<>() );
m_pTreeView->SetTreePath( sURL );
m_pTreeView->SetSelectHdl( LINK( this, RemoteFilesDialog, TreeSelectHdl ) );
if( eResult == eSuccess )
{
m_pPath->SetURL( sURL );
m_bIsConnected = true;
EnableControls();
}
m_pTreeView->SetSelectHdl( Link<>() );
m_pTreeView->SetTreePath( sURL );
m_pTreeView->SetSelectHdl( LINK( this, RemoteFilesDialog, TreeSelectHdl ) );
m_bIsConnected = true;
EnableControls();
}
SetPointer( PointerStyle::Arrow );
EnableChildPointerOverwrite( false );
SetPointer( PointerStyle::Arrow );
EnableChildPointerOverwrite( false );
}
else
{
// content doesn't exist
}
}
return eResult;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment