JDownloader Community - Appwork GmbH
 

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 04.11.2020, 14:23
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default Ohne Fensterwechsel "Auswahl in Downloadliste übernehmen"

Hallo,

gibt es eine Möglichkeit/Tastaturkürzel einzelne Dateien im Linksammler in die Downloadliste, ohne Fensterwechsel zu übernehmen? Es kommt immer mal vor, dass man von einer Downloadliste nichte alle Dateien übernehmen möchte und einzelne Dateien nach und nach selektiert.
Reply With Quote
  #2  
Old 04.11.2020, 15:25
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Advanced Setting:
Code:
LinkgrabberSettings.autoswitchtodownloadtableonconfirmdefaultenabled
Reply With Quote
  #3  
Old 04.11.2020, 15:27
pspzockerscene's Avatar
pspzockerscene pspzockerscene is offline
Community Manager
 
Join Date: Mar 2009
Location: Deutschland
Posts: 71,140
Default

Hi,
es gibt (aktuell) keinen einfachen Weg, diese Einstellung temporär zu ändern.
Es gibt die globale unter:
Einstellungen -> Profieinstellungen ->
Code:
LinkgrabberSettings: Auto Switch To Download Table On Confirm Default
Hier sind deine Optionen:
1. Du erstellst dir ein EventScripter Script, das die erwähnte Einstellung schnell aktiviert/deaktiviert und dann deine markierten Links in die Downloadliste schiebt.
oder
2. Ich erstelle ein Ticket und dieses Feature wird irgendwann eventuell als Teil der "Add to Downloadlist" Action des Linkgrabbers eingebaut.
Sollte das passieren, könntest du einfach einen eigene Kontextmenü-Action dafür hinzufügen (bzw. auch Hotkey) und dort entsprechend das Springen in die Downloadliste deaktivieren.
Das wäre dann hier:


Grüße, psp
EDIT
Quote:
Originally Posted by mgpai View Post
Advanced Setting:
Code:
LinkgrabberSettings.autoswitchtodownloadtableonconfirmdefaultenabled
Jup that's the right way but his post read to me as if he wanted to temp. disable this settings or only sometimes wants JD to switch to downloadlist hence my detailed answer.
__________________
JD Supporter, Plugin Dev. & Community Manager

Erste Schritte & Tutorials || JDownloader 2 Setup Download
Spoiler:

A users' JD crashes and the first thing to ask is:
Quote:
Originally Posted by Jiaz View Post
Do you have Nero installed?
Reply With Quote
  #4  
Old 04.11.2020, 16:21
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default

@pspzockerscene Ich würde Lösung zwei bevorzugen. Aber irgendwann eventuell klingt natürlich nicht sehr hoffnungsvoll. Zumindest ist keine schnelle Umsetzung zu erwarten. Die sauberste Lösung für mich wäre es, wenn man bspw. die SHIFT-Taste gedrückt hält und Dateien zur Downloadliste hinzufügt ohne, dass man zum Downloadfenster wechselt. Instinktiv drücke ich allerdings die STRG-Taste - damit öffnet man ja im Browser einen Link in einem neuen Tab ohne Fensterwechsel - doch ist diese Taste bereits belegt.

Einen Ereignis-Skript, der die globale Einstellung per Tastenkombination ein- oder ausschaltet, könnte ich nicht erstellen. Dazu fehlen mir die Programmierkenntnisse.

Trotzdem, vielen Dank mgpai und pspzockerscene für den Hinweis für die globale Einstellung.
Reply With Quote
  #5  
Old 04.11.2020, 16:45
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,339
Default

@hightower: evtl kann dir mpgai bei einem solchen Skript helfen oder du schaltest es einfach dauerhaft global aus
Aktuell ist der Hotkey CTRL/STRG zum wechseln zwischen Hinzufügen und Starten
__________________
JD-Dev & Server-Admin

Last edited by Jiaz; 04.11.2020 at 16:48.
Reply With Quote
  #6  
Old 04.11.2020, 16:56
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default

Quote:
Originally Posted by Jiaz View Post
@hightower: evtl kann dir mpgai bei einem solchen Skript helfen oder du schaltest es einfach dauerhaft global aus
Aktuell ist der Hotkey CTRL/STRG zum wechseln zwischen Hinzufügen und Starten
Richtig, ich sagte ja STRG ist bereits belegt. Oder du baust die Funktion schnell mal ein.

Nee, nur Spaß. Ich habe jetzt erst einmal die globale Einstellung geändert.
Reply With Quote
  #7  
Old 04.11.2020, 17:00
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,339
Default

Da die Funktion eher unter *nice to have* fällt, wird es wohl bissle dauern bis sich mal einer dessen annimmt, hoffe da auf dein Verständnis
__________________
JD-Dev & Server-Admin
Reply With Quote
  #8  
Old 04.11.2020, 17:02
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 79,339
Default

__________________
JD-Dev & Server-Admin
Reply With Quote
  #9  
Old 04.11.2020, 17:29
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Code:
/*
    Toggle switch to download tab on link added
    Trigger: Toolbar button pressed
    Customize main toolbar > Add new 'Eventscripter Trigger' button > Rename it to "Toggle switch to download tab" (case-sensitive) > Change Icon (optional)
*/

if (name == "Toggle switch to download tab") {
    var interfaceName = "org.jdownloader.gui.views.linkgrabber.addlinksdialog.LinkgrabberSettings",
        key = "AutoSwitchToDownloadTableOnConfirmDefaultEnabled",
        value = callAPI("config", "get", interfaceName, null, key),
        message = "Switch to download tab has been " + (value ? "DISABLED" : "ENABLED");

    callAPI("config", "set", interfaceName, null, key, !value);
    alert(message);
}

Last edited by mgpai; 05.11.2020 at 06:21. Reason: Updated script.
Reply With Quote
  #10  
Old 04.11.2020, 19:10
pspzockerscene's Avatar
pspzockerscene pspzockerscene is offline
Community Manager
 
Join Date: Mar 2009
Location: Deutschland
Posts: 71,140
Default

@hightower5
Wie du siehst hat mgpai dir ein Script geschrieben.

Grüße, psp
__________________
JD Supporter, Plugin Dev. & Community Manager

Erste Schritte & Tutorials || JDownloader 2 Setup Download
Spoiler:

A users' JD crashes and the first thing to ask is:
Quote:
Originally Posted by Jiaz View Post
Do you have Nero installed?
Reply With Quote
  #11  
Old 04.11.2020, 19:54
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default

Quote:
Originally Posted by pspzockerscene View Post
@hightower5
Wie du siehst hat mgpai dir ein Script geschrieben.

Grüße, psp
Super, vielen Dank @mgpai. Die Hinweise im Script sind wie immer auf den Punkt und auch sehr wichtig. @pspzockerscene, so richtig trivial finde ich das Erstellen eines Ereignisses selbst mit dem Script nicht.
Reply With Quote
  #12  
Old 04.11.2020, 19:57
pspzockerscene's Avatar
pspzockerscene pspzockerscene is offline
Community Manager
 
Join Date: Mar 2009
Location: Deutschland
Posts: 71,140
Default

Freut mich, dass wir dir helfen konnten.
Man muss es auch nicht per se als Workaround betrachten - der Event Scripter ist ja genau für solche Dinge gedacht.
Wenn man sich überlegt, wie viele User dieses Feature bisher angefragt haben (niemand[?]) reicht das evtl. auch für dich.

Kombiniert mit einer Tastenkombination hättest du damit evtl. zu 100% dein Ziel erreicht.

Grüße, psp
__________________
JD Supporter, Plugin Dev. & Community Manager

Erste Schritte & Tutorials || JDownloader 2 Setup Download
Spoiler:

A users' JD crashes and the first thing to ask is:
Quote:
Originally Posted by Jiaz View Post
Do you have Nero installed?
Reply With Quote
  #13  
Old 05.11.2020, 06:26
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

@hightower5: I have updated the script with additional code which I forgot to include earlier. Please update your script with the new one. Apologies for the inconvenience.
Reply With Quote
  #14  
Old 05.11.2020, 15:50
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default

Quote:
Originally Posted by mgpai View Post
@hightower5: I have updated the script with additional code which I forgot to include earlier. Please update your script with the**External links are only visible to Support Staff**.... Apologies for the inconvenience.
The updated code seems to work. But in the scripter the "test run" doesn't start anymore.
Reply With Quote
  #15  
Old 05.11.2020, 15:58
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by hightower5 View Post
The updated code seems to work. But in the scripter the "test run" doesn't start anymore.
It is because, the script now contains a code which will allow it to run only when a button with specific/matching name is pressed. This is to prevent the script from running when other "Eventscripter Trigger" button with missing/different names are present/pressed in the toolbar.
Reply With Quote
  #16  
Old 05.11.2020, 19:25
hightower5 hightower5 is offline
JD VIP
 
Join Date: Mar 2009
Posts: 341
Default

Für Benutzer, die JD2 auf Deutsch nutzen, hier das Script auf Deutsch:

Code:
/*
    Wechsel zur Downloadliste beim Hinzufügen von Links umschalten
    Auslöser: Werkzeugleisten-Schaltfläche gedrückt
    Hauptwerkzeugleiste anpassen > Neue 'Ereignis-Skripter'-Schaltfläche hinzufügen > In 'Toggle switch to download tab' umbenennen
    (Groß- und Kleinschreibung beachten) > Symbol ändern (optional)
*/

if (name == "Toggle switch to download tab") {
    var interfaceName = "org.jdownloader.gui.views.linkgrabber.addlinksdialog.LinkgrabberSettings",
        key = "AutoSwitchToDownloadTableOnConfirmDefaultEnabled",
        value = callAPI("config", "get", interfaceName, null, key),
        message = "Wechsel zur Downloadliste wurde: " + (value ? "DEAKTIVIERT" : "AKTIVIERT");

    callAPI("config", "set", interfaceName, null, key, !value);
    alert(message);
}

Last edited by hightower5; 09.11.2020 at 20:22. Reason: Update
Reply With Quote
  #17  
Old 07.11.2020, 12:04
jogol's Avatar
jogol jogol is offline
DSL User
 
Join Date: Nov 2015
Location: Deutschland
Posts: 39
Default

Is there a possibily to dynamically add a change of assigned icon for this event scripter via a callAPI call to show state change when the event is triggered? If not you have to remember actual state or toggle twice to see the actual state and have it unchanged.

As far as I can see assigning an icon to the event defined using menu editor is a static thing for displaying the toggle switch.

NB: It's not a big thing though, I can live with this nice addition as it is

Last edited by jogol; 07.11.2020 at 12:11. Reason: NB added
Reply With Quote
  #18  
Old 07.11.2020, 17:54
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,533
Default

Quote:
Originally Posted by jogol View Post
Is there a possibily to dynamically add a change of assigned icon for this event scripter via a callAPI call to show state change when the event is triggered?
Eventscripter currently has no access to menu/toolbar items. There is a pending ticket to add the feature.


Quote:
Originally Posted by jogol View Post
If not you have to remember actual state or toggle twice to see the actual state and have it unchanged.
I you are running JD on Windows OS, you can use the following script which will display dynamic/interactive dialog and change the current value based on user response. Please note, the script will create a vbscript file in JD\tmp folder.

Code:
/*
    Enabled/Disable: Switch to download tab on link added
    Trigger: Toolbar button pressed
    OS: Windows only
    Customize main toolbar > Add new 'Eventscripter Trigger' button > Rename it to "Switch to download tab" (case-sensitive) > Change Icon (optional)
*/

if (name == "Switch to download tab") {
    var interfaceName = "org.jdownloader.gui.views.linkgrabber.addlinksdialog.LinkgrabberSettings",
        key = "AutoSwitchToDownloadTableOnConfirmDefaultEnabled",
        value = callAPI("config", "get", interfaceName, null, key),
        vbs = getPath(JD_HOME + "/tmp/confirm.vbs"),
        message = (value ? "DISABLE" : "ENABLE") + " switch to download tab?";

    if (!vbs.exists()) {
        var script = "message = wScript.Arguments.Item(0)\r\nresult = Msgbox(message,vbYesNo+vbQuestion, \"\")\r\nWScript.Echo result";
        writeFile(vbs, script, true);
    }

    var result = callSync("cscript", vbs, message).trim().match(/(\d)$/)[1];

    if (result == 6) {
        callAPI("config", "set", interfaceName, null, key, !value);
    }
}
Reply With Quote
  #19  
Old 07.11.2020, 20:34
jogol's Avatar
jogol jogol is offline
DSL User
 
Join Date: Nov 2015
Location: Deutschland
Posts: 39
Default

Quote:
Originally Posted by mgpai View Post
Eventscripter currently has no access to menu/toolbar items.
Thanks for the script enhancement. Works like a charm and a nice example of event scripting.

Last edited by jogol; 07.11.2020 at 21:24.
Reply With Quote
  #20  
Old 07.11.2020, 20:48
jogol's Avatar
jogol jogol is offline
DSL User
 
Join Date: Nov 2015
Location: Deutschland
Posts: 39
Default

x

Last edited by jogol; 07.11.2020 at 20:56. Reason: Sorry for empty post - did not know how to cancel this post.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 10:08.
Provided By AppWork GmbH | Privacy | Imprint
Parts of the Design are used from Kirsch designed by Andrew & Austin
Powered by vBulletin® Version 3.8.10 Beta 1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.