Move tab to new window

Discuss development issues and submit patches here
twinsen
Posts: 109
Joined: Mon Dec 27, 2010 3:17 pm

Move tab to new window

Post by twinsen »

Although its not as easy to use as dragging tabs, you can now right click a tab and select "Move Tab to New Window" to move the tab to a new window.
You can also "Duplicate Tab to New Window" instead of the same window.

* Exe: Explorer++_move_to_new_window_mod.7z http://members.iinet.net.au/~bertdb/rya ... dow_mod.7z
* Src: Explorer++_move_to_new_window_src.7z http://members.iinet.net.au/~bertdb/rya ... dow_src.7z

I haven't created a patch yet, but you can diff the files with 1.2 to see the changes.

ajs
Posts: 409
Joined: Mon Jul 05, 2010 6:37 pm

Re: Move tab to new window

Post by ajs »

Hi David,
new patch which adds the changes from twinsen for "startup fix" (http://www.explorerplusplus.com/forum/v ... ?f=7&t=617) and for "move tab" (this thread).

patch against v156.

PS for twinsen: this should have fixed the "strange" character in the .rc file. Can you give it a try and let me know?
Attachments
patch_07__v156.zip
(41.85 KiB) Downloaded 393 times

twinsen
Posts: 109
Joined: Mon Dec 27, 2010 3:17 pm

Re: Move tab to new window

Post by twinsen »

Minor issue. When I apply the patch, it calls GetDiskFreeSpaceEx twice.
Removing the 2nd call fixes it (so the lstrcmpi works fine).

ColumnManager.cpp:

Code: Select all

			// GetDiskFreeSpaceEx is slow for floppy drives (and makes a loud sound)
			// so don't bother getting their label.
			if (lstrcmpi(szItem,_T("A:\\"))!=0 &&
				lstrcmpi(szItem,_T("B:\\"))!=0)
			{
				bRes = GetDiskFreeSpaceEx(szItem,NULL,&nTotalBytes,&nFreeBytes);
			}

			bRes = GetDiskFreeSpaceEx(szItem,NULL,&nTotalBytes,&nFreeBytes);
I haven't tested the gui changes. I still have problems with the rc file, despite your patch file looking fine (the patch file is saying to remove that char). Maybe a newer version of tortoiseSVN handles this character better.
Once David makes a commit that removes the bad character from the afxres.h line, then it should be much easier to apply patches.

ajs
Posts: 409
Joined: Mon Jul 05, 2010 6:37 pm

Re: Move tab to new window

Post by ajs »

twinsen wrote:Minor issue. When I apply the patch, it calls GetDiskFreeSpaceEx twice.
Removing the 2nd call fixes it (so the lstrcmpi works fine).
thanks, just removed the double call right now.
twinsen wrote:I haven't tested the gui changes. I still have problems with the rc file, despite your patch file looking fine (the patch file is saying to remove that char). Maybe a newer version of tortoiseSVN handles this character better.
I have tried to apply the same patch locally on my computer and it doesn't come up with any issue. Maybe it is related to TortoiseSVN as you said, but sounds strange. Or maybe your local copy has the strange character. I have a similar message in Visual Studio editing the resource file .rc as code (incorrect end line character), I choose to "fix" it and then no problem.
Anyhow the "strange" character is just a new line too much, so you can just remove it if it cause a problem. Let's see if David has the same problem or not.

ajs
Posts: 409
Joined: Mon Jul 05, 2010 6:37 pm

Re: Move tab to new window

Post by ajs »

Updated patch against commit 161.
This patch includes only the changes for this function, without any another change made.
Attachments
patch_07__v161.7z
(1.1 KiB) Downloaded 362 times

twinsen
Posts: 109
Joined: Mon Dec 27, 2010 3:17 pm

Re: Move tab to new window

Post by twinsen »

Installing TortoiseSVN 1.6.15 fixed the patch errors for the rc file.
Although I can't reboot at the moment to properly integrate it into explorer, running "TortoiseMerge" from the start menu works fine.
Just select "Apply unified diff", the diff file and directory to patch.

twinsen
Posts: 109
Joined: Mon Dec 27, 2010 3:17 pm

Re: Move tab to new window

Post by twinsen »

Found crash with "Duplicate Tab to New Window"
How to reproduce:
* Tick "Allow multiple instances" in the options
* Close all tabs except one
* Create a new tab of "My Computer"
* Close all tabs except "My Computer"
* "Duplicate Tab to New Window" -> crash
Note: "My Computer" duplicates fine with other tabs, and duplicate to same window works without a crash.

ajs
Posts: 409
Joined: Mon Jul 05, 2010 6:37 pm

Re: Move tab to new window

Post by ajs »

Thanks twinsen,
I will try to reproduce and eventually fix it.

twinsen
Posts: 109
Joined: Mon Dec 27, 2010 3:17 pm

Re: Move tab to new window

Post by twinsen »

I couldn't reproduce the crash on my development pc. But the crash happens every time on another PC (which doesn't have VS2010).
On a related note, I implemented a minidump feature. I noticed there was evidence of an unfinished minidump feature, so it looks like other people wanted it.
Hopefully I can get a minidump of the crash and find out whats so different about this pc.
I'll try and make a patch for the minidump feature soon. If anyone knows ways of crashing explorer++ I'd like to know so I can test how useful the minidumps are.

ajs
Posts: 409
Joined: Mon Jul 05, 2010 6:37 pm

Re: Move tab to new window

Post by ajs »

twinsen wrote:I couldn't reproduce the crash on my development pc. But the crash happens every time on another PC (which doesn't have VS2010).
On a related note, I implemented a minidump feature. I noticed there was evidence of an unfinished minidump feature, so it looks like other people wanted it.
Hopefully I can get a minidump of the crash and find out whats so different about this pc.
I'll try and make a patch for the minidump feature soon. If anyone knows ways of crashing explorer++ I'd like to know so I can test how useful the minidumps are.
Hi twinsen, I forgot to update this post. I can reproduce the problem on my computer, so I will be able to work on it (it is in my list of bug fixes to do).
The minidump feature sounds interesting. As soon as you have a patch ready, please post it.
I hope David starts committing some of the many pending patches... development against so many pending changes if requiring more and more time every new patch.

Post Reply