Source Code Cross Referenced for ColSizeEvent.java in  » Ajax » zk » org » zkoss » zul » event » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Ajax » zk » org.zkoss.zul.event 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /* ColSizeEvent.java
002:
003:        {{IS_NOTE
004:        	Purpose:
005:        		
006:        	Description:
007:        		
008:        	History:
009:        		Thu Dec  7 10:25:43     2006, Created by tomyeh
010:        }}IS_NOTE
011:
012:        Copyright (C) 2006 Potix Corporation. All Rights Reserved.
013:
014:        {{IS_RIGHT
015:        	This program is distributed under GPL Version 2.0 in the hope that
016:        	it will be useful, but WITHOUT ANY WARRANTY.
017:        }}IS_RIGHT
018:         */
019:        package org.zkoss.zul.event;
020:
021:        import org.zkoss.zk.ui.Component;
022:        import org.zkoss.zk.ui.event.Event;
023:        import org.zkoss.zk.ui.event.MouseEvent;
024:
025:        /**
026:         * Used to notify that the widths of two adjacent column are changed.
027:         *
028:         * <p>When an user drags the border of sizable columns, the width of the
029:         * adjacent columns are changed accordingly -
030:         * one is enlarged, the other is shrinked and the total width is not changed.
031:         *
032:         * <p>The event is sent to the parent (e.g., {@link org.zkoss.zul.Columns}
033:         * and {@link org.zkoss.zul.Treecols}).
034:         * 
035:         * @author tomyeh
036:         */
037:        public class ColSizeEvent extends Event {
038:            private final Component _col;
039:            private final int _icol, _keys;
040:
041:            /** Indicates whether the Alt key is pressed.
042:             * It might be returned as part of {@link #getKeys}.
043:             */
044:            public static final int ALT_KEY = MouseEvent.ALT_KEY;
045:            /** Indicates whether the Ctrl key is pressed.
046:             * It might be returned as part of {@link #getKeys}.
047:             */
048:            public static final int CTRL_KEY = MouseEvent.CTRL_KEY;
049:            /** Indicates whether the Shift key is pressed.
050:             * It might be returned as part of {@link #getKeys}.
051:             */
052:            public static final int SHIFT_KEY = MouseEvent.SHIFT_KEY;
053:
054:            /** Constructs an instance of {@link ColSizeEvent}.
055:             *
056:             * @param icol the index of the first colum whose width is changed.
057:             * The second column is icol+1.
058:             */
059:            public ColSizeEvent(String evtnm, Component target, int icol,
060:                    Component col, int keys) {
061:                super (evtnm, target);
062:                _icol = icol;
063:                _col = col;
064:                _keys = keys;
065:            }
066:
067:            /**
068:             * @param icol the index of the first colum whose width is changed.
069:             * The second column is icol+1.
070:             * @deprecated As of release 3.0.0, since only one column is resized.
071:             */
072:            public ColSizeEvent(String evtnm, Component target, int icol,
073:                    Component col1, Component col2, int keys) {
074:                this (evtnm, target, icol, col1, keys);
075:            }
076:
077:            /** Return the column index of the first column whose width is changed.
078:             * The other column is the returned index plus one.
079:             * <p>In other words, it is the index (starting from 0) of {@link #getColumn1}.
080:             */
081:            public int getColIndex() {
082:                return _icol;
083:            }
084:
085:            /** Returns the column whose width is changed.
086:             * @since 3.0.0
087:             */
088:            public Component getColumn() {
089:                return _col;
090:            }
091:
092:            /** Returns the first column whose width is changed.
093:             * @deprecated As of release 3.0.0, use {@link #getColumn} instead,
094:             * since only one column is resized
095:             */
096:            public Component getColumn1() {
097:                return getColumn();
098:            }
099:
100:            /** Returns the second column whose width is changed.
101:             * @deprecated As of release 3.0.0, since only one column is resized.
102:             * It always returns null since 3.0.0
103:             */
104:            public Component getColumn2() {
105:                return null;
106:            }
107:
108:            /** Returns what keys were pressed when the column is resized, or 0 if
109:             * none of them was pressed.
110:             * It is a combination of {@link #CTRL_KEY}, {@link #SHIFT_KEY}
111:             * and {@link #ALT_KEY}.
112:             */
113:            public final int getKeys() {
114:                return _keys;
115:            }
116:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.