eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'SimpleDialog':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: SimpleDialog


Inheritance:

   Object
   |
   +--Model
      |
      +--ApplicationModel
         |
         +--SimpleDialog
            |
            +--AbstractSettingsApplication::SourceCodeManagementSettingsAppl::PerModuleManagerSettingDialog
            |
            +--BookmarkEditor
            |
            +--BookmarksEditDialog
            |
            +--FileDialog
            |
            +--PerforceSourceCodeManagerUtilities::P4CheckinInfoDialog
            |
            +--PerforceSourceCodeManagerUtilities::SubmitInfoDialog
            |
            +--Tools::ChangeSetDiffTool::OpenDialog
            |
            +--Tools::ChangeSetSelectionDialog
            |
            +--Tools::CheckinInfoDialog
            |
            +--Tools::HierarchicalChangesetDialog
            |
            +--Tools::LintRuleEditDialog
            |
            +--Tools::LintRuleSelectionDialog
            |
            +--Tools::NewClassWizardDialog
            |
            +--Tools::ProjectLoader

Package:
stx:libview2
Category:
Interface-Framework
Version:
rev: 1.65 date: 2019/08/15 11:05:38
user: cg
file: SimpleDialog.st directory: libview2
module: stx stc-classLibrary: libview2
Author:
Claus Gittinger

Description:


Use SimpleDialog to specify Dialogs with a windowSpec built by the GUI Builder.

Notice: this class was implemented using protocol information
from alpha testers and PD code - it may not be complete or compatible to
the corresponding ST-80 class. If you encounter any incompatibilities,
please forward a note to the ST/X team.

Hints:
    to provide a helpSpec, either add it to the builder's bindings;
    (I will fetch help also via: 'self aspectFor:#helpSpec')
    or define the dialog's masterApplication
    (I will ask it for help texts then)


Related information:

    StandardSystemView
    WindowGroup
    DeviceWorkstation
    DialogBox

Class protocol:

queries
o  isVisualStartable
return true, if this application can be started via #open.
(to allow start of a change browser via double-click in the browser)


Instance protocol:

DialogBox compatibility
o  destroy

o  hide

accessing
o  accept
return the valueholder which gets set to true by the accept button.
Also, when this valueHolder gets a true stuffed into it, the dialog is closed.
This valueHolder is also set to true, if the acceptValue get a value stored into.

o  acceptValue: something
save something in acceptedValue (to be passed back to the opened of this dialog),
and set the accept-holder to true, which closes the dialog window.
This is similar to a regular accept, but allows for a particular return-value to be passed
back.

o  accepted
after the box has closed:
return true if accepted, false if canceled

o  acceptedValue
an additional value which can be passed back to the one who opened a dialog

o  bindings
return my builder's bindings

o  cancel
return the valueholder which gets set by the cancel button.
Also, when this valueHolder gets a true stuffed into it, the
dialog is closed.

o  escapeIsCancel
return the escapeIsCancel setting

o  escapeIsCancel: something
set/clear the escapeIsCancel option.
If on, an ESC-key will be treated like a cancel action.

o  postBuildBlock: something
set postBuildBlock; if non-nil, this is evaluated after the build process

o  postOpenBlock: something
set the postBuildBlock; if non-nil, this is evaluated after the view is opened

o  preBuildBlock: something
set the preBuildBlock; if non-nil, this is evaluated before the view is constructed

o  source: anApplication
define the application which provides resources, aspects etc.

accessing-channels
o  closeAllowedChannel
return the value-provider which controls if close is allowed.
This is initialized to true.

o  closeAllowedChannel: aValueHolderOrBlock
set a value-provider which controls if close is allowed.

o  closeChannel
return the closeChannel; If a true is stuffed into this valueHolder,
I will close myself.

accessing-window
o  minWidth: nPixels
box := builder window displayBox.

events
o  closeAccept
accept was pressed. close the dialog

o  closeCancel
cancel was pressed. close the dialog

o  closeWindow
close the dialog

o  requestForWindowClose
the dialog is about to be closed - this method is invoked and may
return false to suppress the close.
Here the value of closeAllowedChannel is returned, which is
set to true initially.
You may redefined this in a special dialog, and/or provide a boolean
valueHolder or a boolean block via the #closeAllowedChannel: method.

forced actions
o  doAccept
force accept

o  doCancel
force cancel

initialization
o  initialize
must be called if redefined

o  initializeBuilderFor: aView

o  initializeWindowFor: aView

opening-dialogInterface
o  allButOpenFor: anApplication interfaceSpec: aSpec withBindings: bindings
open the dialog for some appModel from a given spec;
the bindings argument may provide overwriting bindings for the dialog.
Return true if accepted, false if canceled

o  allButOpenFrom: aSpec
create my views but do not open the main window

o  openFor: anApplication interface: aSelector
open the dialog for some appModel from a given spec;
Return true if accepted, false if canceled

o  openFor: anApplication interface: anInterfaceSymbolOrSpec withBindings: bindings
open the dialog for some appModel from a given specSymbol;
the application must provide an interfaceSpec for that symbol.
The bindings argument may provide overwriting bindings for the
dialog.
Return true if accepted, false if canceled

o  openFor: anApplication interfaceSpec: aSpec withBindings: bindings
open the dialog for some appModel from a given spec;
the bindings argument may provide overwriting bindings for the
dialog.
Return true if accepted, false if canceled

o  openFor: anApplication spec: aSpec withBindings: bindings
open the dialog for some appModel from a given spec.
The bindings argument may provide overwriting bindings for the
dialog.
Return true if accepted, false if canceled

o  openFrom: anInterfaceSpec
open the dialog from a given spec;
return true if accepted, false if canceled

o  openInterface: aSymbol
open a standard interface.
Redefined to return the accept value instead of the builder.

o  openInterface: aSymbol at: position
open a standard interface.
Redefined to return the accept value instead of the builder.

o  openModelessFor: anApplication interfaceSpec: aSpec withBindings: bindings
open the dialog for some appModel from a given spec;
the bindings argument may provide overwriting bindings for the
dialog.
Return immediately, not blocking the caller

o  openModelessFor: anApplication spec: aSpec withBindings: bindings
open the dialog for some appModel from a given spec.
The bindings argument may provide overwriting bindings for the
dialog.
Return immediately (i.e non-blocking the caller)

o  openSpec: aWindowSpec
open a window spec.
Redefned to open modal and to return the accept value instead
of the builder.

o  openSpec: anInterfaceSpec withBindings: bindings
open the dialog with a given spec;
The bindings argument is mandatory and provides aspect bindings for the
dialog.
Return true if accepted, false if canceled

o  postBuildWith: aBuilder
this is sent after the dialog's widgets have been created
(but before the dialog is opened).
If a postBuildBlock was set, evaluate it here.

o  postOpenWith: aBuilder
this is sent after the dialog's main window is opened.
If a postOpenBlock was set, evaluate it here.

o  preBuildWith: aBuilder
this is sent before the dialog's widgets are created.
If a preBuildBlock was set, evaluate it here.

o  preOpen
arrange for #closeAccept & #closeCancel to be invoked when
either accept or close is triggered
(usually the models of corresponding buttons)

o  preOpenWith: aBuilder
this is sent after the dialog's main window is opened.
If a postOpenBlock was set, evaluate it here.

queries
o  defaultWindowType
SimpleDialogs come up modal, by default

o  shouldRememberLastExtent
(comment from inherited method)
to be redefined by concrete applications:
if true is answered, the application's extent is remembered on close
and used as a default when opened the next time



ST/X 7.2.0.0; WebServer 1.670 at bd0aa1f87cdd.unknown:8081; Tue, 23 Apr 2024 21:28:12 GMT