-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #331 from Pixelated-Grunt/import_filter
ESE - Add import from clipboard into Available Items
- Loading branch information
Showing
9 changed files
with
122 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/* | ||
Author: Pixelated_Grunt | ||
Date: 2024-08-29 | ||
Description: | ||
Used by the ENH_ESE GUI. Import a list from clipboard to the available list (left panel). | ||
The import list is same as ACE arsenal export format i.e. ["item1", "item2"]. | ||
Parameter(s): | ||
- | ||
Returns: | ||
- | ||
*/ | ||
|
||
|
||
#include "\x\enh\addons\main\script_component.hpp" | ||
private _allAttributes = [true] call ENH_fnc_ESE_parseClipboardValues; | ||
private _display = uiNamespace getVariable ["ENH_Display_ESE", displayNull]; | ||
|
||
// Backup the existing ENH_ESE_itemsHashMap | ||
uiNamespace setVariable ["ENH_ESE_itemsHashMapClone", uiNamespace getVariable ["ENH_ESE_itemsHashMap", createHashMap]]; | ||
// Replace the hashmap | ||
uiNamespace setVariable ["ENH_ESE_itemsHashMap", _allAttributes]; | ||
// Call change filter to trigger the list update | ||
[CTRL(IDC_ESE_MENU), [2, 0]] call ENH_fnc_ESE_changeFilter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/* | ||
Author: Pixelated_Grunt | ||
Date: 2024-08-29 | ||
Description: | ||
Used by the ENH_ESE GUI. Reset the filter list (left panel) back to all available items. | ||
Parameter(s): | ||
- | ||
Returns: | ||
- | ||
*/ | ||
|
||
|
||
#include "\x\enh\addons\main\script_component.hpp" | ||
private _display = uiNamespace getVariable ["ENH_Display_ESE", displayNull]; | ||
|
||
// Restore the ENH_ESE_itemsHashMap variable | ||
uiNamespace setVariable ["ENH_ESE_itemsHashMap", uiNamespace getVariable "ENH_ESE_itemsHashMapClone"]; | ||
// Release the memory | ||
uiNamespace setVariable ["ENH_ESE_itemsHashMapClone", nil]; | ||
// Call change filter to trigger the list update | ||
[CTRL(IDC_ESE_MENU), [2, 0]] call ENH_fnc_ESE_changeFilter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters