Skip to content

Commit

Permalink
Add "Plugin Communication Guide" & "Get Plugin Demo Source Code" comm…
Browse files Browse the repository at this point in the history
…ands
  • Loading branch information
donho committed Jan 28, 2024
1 parent 9f74417 commit a564ea6
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 4 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/CI_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Archive artifacts for x64
if: matrix.build_platform == 'x64' && matrix.build_configuration == 'Release'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
path: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
Expand All @@ -48,7 +48,7 @@ jobs:
- name: Archive artifacts for Win32
if: matrix.build_platform == 'Win32' && matrix.build_configuration == 'Release'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
path: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
Expand All @@ -62,7 +62,7 @@ jobs:
- name: Archive artifacts for ARM64
if: matrix.build_platform == 'ARM64' && matrix.build_configuration == 'Release'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
path: pluginDemo_${{ steps.tagName.outputs.tag }}_${{ matrix.build_platform }}.zip
Expand Down
16 changes: 16 additions & 0 deletions src/PluginDefinition.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,11 @@ void commandMenuInit()
setCommand(14, TEXT("---"), NULL, NULL, false);

setCommand(DOCKABLE_DEMO_INDEX, TEXT("Dockable Dialog Demo"), DockableDlgDemo, NULL, false);

setCommand(16, TEXT("---"), NULL, NULL, false);

setCommand(17, TEXT("Plugin Communication Guide"), goToPluginCommunicationGuide, NULL, false);
setCommand(18, TEXT("Get Plugin Demo Source Code"), goToPluginDemoRepo, NULL, false);
}


Expand Down Expand Up @@ -307,6 +312,8 @@ void insertCurrentPath(int which)
#endif
}



void insertCurrentFullPath()
{
insertCurrentPath(FULL_CURRENT_PATH);
Expand Down Expand Up @@ -458,3 +465,12 @@ void DockableDlgDemo()
_goToLine.display();
}

void goToPluginCommunicationGuide()
{
::ShellExecute(NULL, TEXT("open"), TEXT("https://npp-user-manual.org/docs/plugin-communication/"), NULL, NULL, SW_SHOWNORMAL);
}

void goToPluginDemoRepo()
{
::ShellExecute(NULL, TEXT("open"), TEXT("https://github.com/npp-plugins/plugindemo"), NULL, NULL, SW_SHOWNORMAL);
}
5 changes: 4 additions & 1 deletion src/PluginDefinition.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const TCHAR NPP_PLUGIN_NAME[] = TEXT("Notepad++ plugin demo");
//
// Here define the number of your plugin commands
//
const int nbFunc = 16;
const int nbFunc = 19;


//
Expand Down Expand Up @@ -85,6 +85,9 @@ void getFileNamesDemo();
void getSessionFileNamesDemo();
void saveCurrentSessionDemo();
void DockableDlgDemo();
void goToPluginCommunicationGuide();
void goToPluginDemoRepo();



#endif //PLUGINDEFINITION_H

0 comments on commit a564ea6

Please sign in to comment.