aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Nodsu's Patch for Preview in Remote GUI  (Read 2344 times)

chemical

  • Jr. Member
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 61
Nodsu's Patch for Preview in Remote GUI
« on: February 12, 2008, 11:47:46 AM »

Quote
        Nodsu:
                * Patch to enable preview in remote GUI.

I really appreciate this patch as I always use a windows remote GUI to a linux amuled running on my router. This patch seems to work fine, however theres a caveat preventing the success for me:

Amulegui on my windows system obviously prefixes the filename of the partfile with a slash. This might be correct on unices, on Windows however it leads to the following construct:

H:\amule\temp/05.part

This string is handed over to VLC which doesn't accept the path. Would it be possible to check for Win32 during compilation and use a backslash instead of a slash then?

Thanks!
chemical
Logged

Kry

  • Ex-developer
  • Retired admin
  • Hero Member
  • *****
  • Karma: -665
  • Offline Offline
  • Posts: 5795
Re: Nodsu's Patch for Preview in Remote GUI
« Reply #1 on: February 12, 2008, 12:19:26 PM »

There's a wx function for that.
Logged

chemical

  • Jr. Member
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 61
Re: Nodsu's Patch for Preview in Remote GUI
« Reply #2 on: February 12, 2008, 06:01:47 PM »

Maybe ... hm. How should.. How am I supposed hmm. hm. Nevermind. Thanks anyway.
Logged

Xaignar

  • Admin and Code Junky
  • Hero Member
  • *****
  • Karma: 19
  • Offline Offline
  • Posts: 1103
Re: Nodsu's Patch for Preview in Remote GUI
« Reply #3 on: February 12, 2008, 09:18:27 PM »

That's should be fixed in current SVN, as part of different commit:
Code: [Select]
- wxString fileWithoutMet;
- fileWithoutMet <<
- thePrefs::GetTempDir() << wxT("/") <<
- file->GetPartMetFileName().RemoveExt().GetRaw();
+ wxString fileWithoutMet = file->GetFullName().RemoveExt().GetRaw();
Logged

chemical

  • Jr. Member
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 61
Re: Nodsu's Patch for Preview in Remote GUI
« Reply #4 on: February 12, 2008, 09:23:14 PM »

Are you sure that file->GetFullName() returns the path I set as a Temp-Directory in the remote GUI? This directory is different than the one thats set up in the daemon.

Obviously thePrefs::GetTempDir() returned the right one, I don't know about the GetFullName().
« Last Edit: February 12, 2008, 09:28:28 PM by chemical »
Logged