From 2bd203cd0411faadbbd9d9d87b5824985bbe9e09 Mon Sep 17 00:00:00 2001 From: CyrilFerlicot Date: Tue, 8 Jan 2019 00:41:30 +0100 Subject: [PATCH 1/2] Add world menu command to open demo. Fixes #215 --- .../MaterialDesignLite.class.st | 17 ++++++++++ .../MDLDemo.class.st | 34 ++++++++++++++++++- 2 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 src/Material-Design-Lite-Core/MaterialDesignLite.class.st diff --git a/src/Material-Design-Lite-Core/MaterialDesignLite.class.st b/src/Material-Design-Lite-Core/MaterialDesignLite.class.st new file mode 100644 index 00000000..7d2bed1d --- /dev/null +++ b/src/Material-Design-Lite-Core/MaterialDesignLite.class.st @@ -0,0 +1,17 @@ +" +Description +-------------------- + +I am an empty class to manage infrastructure stuff +" +Class { + #name : #MaterialDesignLite, + #superclass : #Object, + #category : #'Material-Design-Lite-Core' +} + +{ #category : #'world-menu' } +MaterialDesignLite class >> mainMenuCommandOn: aBuilder [ + + (aBuilder item: #MaterialDesignLite) order: 20 +] diff --git a/src/Material-Design-Lite-Demo/MDLDemo.class.st b/src/Material-Design-Lite-Demo/MDLDemo.class.st index 911f1db1..f9486520 100644 --- a/src/Material-Design-Lite-Demo/MDLDemo.class.st +++ b/src/Material-Design-Lite-Demo/MDLDemo.class.st @@ -47,9 +47,41 @@ MDLDemo class >> initializeAs: aString [ yourself ] +{ #category : #'world menu' } +MDLDemo class >> menuCommandOn: aBuilder [ + + (aBuilder item: #'Open demo in default browser') + order: 2; + iconName: #nautilus; + parent: #MaterialDesignLite; + help: 'Open the demo in the default web browser'; + action: [ self open ]. +] + +{ #category : #'instance creation' } +MDLDemo class >> open [ +