Commit cd02dd6d authored by Albert Astals Cid's avatar Albert Astals Cid

Minor changes

Make the receivers be the ones that check for empty, not the senders
parent 89fd56c2
......@@ -990,7 +990,10 @@ void Part::openUrlFromBookmarks(const KUrl &_url)
void Part::handleDroppedUrls( const KUrl::List& urls )
{
if( m_embedMode != NativeShellMode || !openNewFilesInTabs() )
if ( urls.isEmpty() )
return;
if ( m_embedMode != NativeShellMode || !openNewFilesInTabs() )
{
openUrlFromDocument( urls.first() );
return;
......
......@@ -642,8 +642,7 @@ void Shell::testTabDrop( const QDragMoveEvent* event, bool& accept )
void Shell::handleTabDrop( QDropEvent* event )
{
const KUrl::List list = KUrl::List::fromMimeData( event->mimeData() );
if( !list.isEmpty() )
handleDroppedUrls( list );
handleDroppedUrls( list );
}
#include "shell.moc"
......
......@@ -762,8 +762,7 @@ void Sidebar::dragEnterEvent( QDragEnterEvent* event )
void Sidebar::dropEvent( QDropEvent* event )
{
const KUrl::List list = KUrl::List::fromMimeData( event->mimeData() );
if( !list.isEmpty() )
emit urlsDropped( list );
emit urlsDropped( list );
}
#include "sidebar.moc"
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