Bug 153213 - KRDC displays remote desktops in wrong tabs when opening more than 2 RDC connections.
Summary: KRDC displays remote desktops in wrong tabs when opening more than 2 RDC conn...
Status: RESOLVED FIXED
Alias: None
Product: krdc
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Urs Wolfer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-01 14:00 UTC by Yuri Timenkov
Modified: 2007-12-03 20:10 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screenshot with misplaced views (57.39 KB, image/png)
2007-12-01 14:04 UTC, Yuri Timenkov
Details
KRDC console output (962 bytes, application/x-gzip)
2007-12-03 13:59 UTC, Yuri Timenkov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yuri Timenkov 2007-12-01 14:00:26 UTC
Version:           3.96.00 (using KDE KDE 3.96.0)
Installed from:    Ubuntu Packages
OS:                Linux

When I open third RDP connection, the third and second screens are displayed on the same tab, and third one is empty.
I use:
rdesktop: A Remote Desktop Protocol client.
Version 1.5.0. Copyright (C) 1999-2005 Matt Chapman.
This issue appeared on the first SVN builds of krdc when tabbed interface was announced (And I periodically build KDE from SVN in hope that this bug will be fixed, because this tabbed interface is incredible!)
I open most of connections in 1024x768x16 resolution, but I have 3-head Xinerama configuration, may be problem is here, but As I remember in Xephyr session this bug appeared too.
See attached screenshot.

500      16981 16967  0 15:36 pts/3    00:00:00 rdesktop -g 1024x768 -k en-us -u administrateur -p XXXXXX -X 14699432 -a 16 -r sound:off mccp5.qa.sw.ru:3389
500      17248 16967  0 15:59 pts/3    00:00:00 rdesktop -g 1024x768 -k en-us -u administrateur -p XXXXXX -X 14725692 -a 16 -r sound:local mccp1.qa.sw.ru:3389
500      17252 16967  0 15:59 pts/3    00:00:00 rdesktop -g 1024x768 -k en-us -u administrator -p XXXXXX -X 14728430 -a 16 -r sound:off mccp2.qa.sw.ru:3389
Comment 1 Yuri Timenkov 2007-12-01 14:04:22 UTC
Created attachment 22267 [details]
Screenshot with misplaced views

mccp5 tab (first) is displayed properly,
second tab (mccp1) is empty.
And connections from second and third tabs are both displayed on third tab.
Comment 2 Urs Wolfer 2007-12-02 22:09:56 UTC
Can you please start KRDC from Konsole, so that you can paste the whole debug output? I think that could help me. Just be sure that you do not paste any sensitive data (e.g. passwords) here. Thanks.
Comment 3 Yuri Timenkov 2007-12-03 13:59:11 UTC
Created attachment 22304 [details]
KRDC console output

Today I checked out KDE svn from trunk. bug still exists.
I noticed that misplacement occurs then new (third) tab is allocated (the RDP
view from second tab moves to new one) and preferences dialog is shown.
Also, i use mainstream qt from gutsy, instead of qt-kdecopy, if it will help.
Comment 4 Yuri Timenkov 2007-12-03 16:08:53 UTC
I suppose I found where bug:
svn diff -r 684033 mainwindow.cpp

-    scrollArea->setWidget(m_remoteViewList.at(m_tabWidget->count()));
+    scrollArea->setWidget(m_remoteViewList.at(m_tabWidget->count() - m_showStartPage ? 1 : 0));

The hack solution is to replace to
    scrollArea->setWidget(m_remoteViewList.at(m_tabWidget->count() - m_showStartPage));

And this works (Assuming (int)true == 1), but it is better to rewrite condition or even generalize dependency on m_showStartPage, because there are many places like: int i = m_showStartPage ? 1 : 0;

But it is not time to refactor code :(
Comment 5 Urs Wolfer 2007-12-03 20:10:34 UTC
SVN commit 744478 by uwolfer:

Fix: KRDC with more than two open tabs works now too.
Thanks Yuri Timenkov for pointing in the right direction. Please verify if that fixes the problem for you. Thanks!
BUG: 153213

 M  +3 -3      mainwindow.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=744478