eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'PluggableDropView':

Home

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

Class: PluggableDropView


Inheritance:

   Object
   |
   +--GraphicsMedium
      |
      +--DisplaySurface
         |
         +--SimpleView
            |
            +--View
               |
               +--PluggableDropView

Package:
stx:libview2
Category:
Views-Basic
Version:
rev: 1.4 date: 2021/02/16 00:51:15
user: cg
file: PluggableDropView.st directory: libview2
module: stx stc-classLibrary: libview2
Author:
cg

Description:


a view which can be configured to handle drops


Instance protocol:

accessing
o  canDropHandler: aBlockOrValueHolder
Modified (format): / 16-02-2021 / 01:49:47 / cg

o  dropHandler: something

drag & drop
o  canDrop: dropObjects
invoked to ask if objects can be dropped;
true if no canDropHandler is defined

o  dropObjects: dropObjects
invoked to actually drop those objects;
call the defined dropHandler


Examples:


embedded in another view:
   |top v|

   top := StandardSystemView new.
   top extent:300@300.
   v := PluggableDropView new.
   v origin:10@10 corner:150@150.
   top add:v.

   v canDropHandler:[:dropObjects| true].
   v dropHandler:[:dropObjects| Transcript showCR:e'dropped {dropObjects}'].

   top open


ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Sat, 23 Nov 2024 13:24:15 GMT