Powershell GUI fronted (WPF) to run categorized console scripts

⌈⌋ ⎇ branch:  ClickyColoury


Check-in [e419d52757]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Cancel button = currently just hangs both runspaces.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: e419d527578b83179fba54520c2906554bec240c
User & Date: mario 2018-05-16 18:09:08
Context
2018-05-16
18:09
Keep old 3-pane CLI menu (for TextyTypey) as plugin. check-in: 7ca24d3342 user: mario tags: trunk
18:09
Cancel button = currently just hangs both runspaces. check-in: e419d52757 user: mario tags: trunk
18:08
Swirly arrow indicator for Window title - when scripts are running. check-in: e076d85d3d user: mario tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Added contrib/CancelBtnExit.ps1.































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# encoding: utf-8
# api: clicky
# type: init
# version: 0.0
# title: Cancel=Exit
# description: hooks [Cancel] button event up to plain exit; call
# category: ui
# state: buggy
# hidden: 1
# nomenu: 1
#
# The [X] cancel UI button has no default handler. Triggering an
# exception across runspaces has proven difficult. Hence this plugin
# turns it into an elaborate exit call (effectively crashing main and
# WPF thread).
#

if ($GUI) {
    $plugins.before += {
        Unregister-Event "Gui.Cancel"
        Register-EngineEvent "Gui.Cancel" -Action {
            $GUI.w.close()
            $GUI.shell.Runspace.CloseAsync();
            $PSHost.CloseAsync();
            $GUI.shell.EndInvoke();
            $PSHost.Dispose();
            exit
        }
    }
}