forked from livecode/livecode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeleteImage.xml
More file actions
45 lines (45 loc) · 2.11 KB
/
Copy pathdeleteImage.xml
File metadata and controls
45 lines (45 loc) · 2.11 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<doc>
<legacy_id>1295</legacy_id>
<name>deleteImage</name>
<type>message</type>
<syntax>
<example>deleteImage</example>
</syntax>
<library></library>
<objects>
<image/>
</objects>
<synonyms>
</synonyms>
<classification>
<category>Objects & Messages</category>
</classification>
<references>
<command tag="delete">delete Command</command>
</references>
<history>
<introduced version="1.0">Added.</introduced>
</history>
<platforms>
<mac/>
<windows/>
<linux/>
<ios/>
<android/>
</platforms>
<classes>
<desktop/>
<server/>
<web/>
<mobile/>
</classes>
<security>
</security>
<summary>Sent to an <keyword tag="image">image</keyword> just before it is removed from the <object tag="stack">stack</object>.</summary>
<examples>
<example>on deleteImage</p><p> export the target to file "Saved"</p><p> pass deleteImage</p><p>end deleteImage</example>
</examples>
<description>
<p>Handle the <b>deleteImage</b> message if you want to perform cleanup before an <keyword tag="image">image</keyword> is removed from the <object tag="stack">stack</object>.</p><p/><p><b>Comments:</b></p><p>The actual deletion is not triggered by the <b>deleteImage</b> <keyword tag="message box">message</keyword>, so <glossary tag="trap">trapping</glossary> the <keyword tag="message box">message</keyword> and not allowing it to <control_st tag="pass">pass</control_st> does not prevent the <keyword tag="image">image</keyword> from being removed.</p><p/><p>However, the <b>undo</b> <glossary tag="command">command</glossary> will restore an <keyword tag="image">image</keyword> after it is deleted by the user. For example, the following <glossary tag="handler">handler</glossary>, placed in a <keyword tag="card">card</keyword> or stack <property tag="script">script</property>, effectively prevents an <keyword tag="image">image</keyword> from being deleted by the user:</p><p/><p><code> on deleteImage</code></p><p><code> beep</code></p><p><code> send "undo" to this card in 5 milliseconds</code></p><p><code> end deleteImage</code></p>
</description>
</doc>