Summary: | The desktop is scrollable when icons are dragged below the panel | ||
---|---|---|---|
Product: | [Unmaintained] kdesktop | Reporter: | bokonon |
Component: | icons | Assignee: | David Faure <faure> |
Status: | CLOSED FIXED | ||
Severity: | normal | CC: | ana, finex, kde, opensource |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | RedHat Enterprise Linux | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
bokonon
2002-04-08 03:41:52 UTC
This bug is still present. To replicate, make sure to have enough icons on the desktop. Then Icons->Line up vertically. Now use konqueror to download something to the desktop. Even though most of the time the icons of the downloaded file will be in the visible area of the desktop, the desktop is still scrollable when dragging a rubber band to the bottom of the screen. *** Bug 48865 has been marked as a duplicate of this bug. *** I can confirm this on KDE 3.1.4 on Debian. Also reproducable on KDE 3.2 RC1 This seems a duplicate of #46316 to me. Also, it is reproduceable with KDE 3.2.1. Still present in CVS at 27/7/04. This bug is still in cvs and is going to be passed to kde 3.3.0 final. I can provide screenshots very fast if you write me. - Reply to this bug - Write to ktech@wanadoo.es It's not a very bad bug, but gives a very bad looking to kde. Thanks. like all the other 5000 open bug reports. I would say, not too many users drag their icons so far, so I don't consider it of major importance. If you got a fix, let us know. This happens to me without the icons going to far. Hiding and bring back the taskbar would fix it before, or refreshing the desktop but with 3.3 I can't get it to go away. A tid bit annoying with my OCD'ish habits. *** Bug 90066 has been marked as a duplicate of this bug. *** The bug can still be reproduced in 3.3.2. 2Stephan Kulow: Maybe it's true, that not too many users drag their icons so far -- but some people may have arranged the icons randomly. Then it's enough to have icon placed on the bottom of the screen, entitled by one line of text ("textfile" for example), then I rename it so that it gets two lines as a title ("textfile textfile"). Then again, the lower end of the icon is off screen. SVN commit 567551 by kling: If icons are dragged outside the desktop area, jerk them back in. Fixes the long-hated issue with the desktop becoming scrollable. BUG: 40418 M +32 -0 kdiconview.cc --- branches/KDE/3.5/kdebase/kdesktop/kdiconview.cc #567550:567551 @@ -1361,6 +1361,38 @@ setLastIconPosition( e->pos() ); KonqIconViewWidget::contentsDropEvent( e ); } + + // Check if any items have been moved outside the desktop area. + // If we find any, move them right back in there. (#40418) + QRect desk = desktopRect(); + bool adjustedAnyItems = false; + for( QIconViewItem *item = firstItem(); item; item = item->nextItem() ) + { + if( !desk.contains( item->rect(), true )) + { + QRect r = item->rect(); + + if( r.top() < 0 ) + r.moveTop( 0 ); + if( r.bottom() > rect().bottom() ) + r.moveBottom( rect().bottom() ); + if( r.left() < 0 ) + r.moveLeft( 0 ); + if( r.right() > rect().right() ) + r.moveRight( rect().right() ); + + item->move( r.x(), r.y() ); + adjustedAnyItems = true; + } + } + if( adjustedAnyItems ) + { + // Make sure the viewport isn't unnecessarily resized by now, + // then schedule a repaint to remove any garbage pixels. + resizeContents( width(), height() ); + viewport()->update(); + } + if (QIconDrag::canDecode(e)) { emit iconMoved(); if ( !m_autoAlign ) // if autoAlign, positions were saved in lineupIcons Bug closed. Kdesktop is no more mantained. |