@@ -40,9 +40,9 @@ pub enum Event {
4040 /// The window was resized
4141 Resized {
4242 /// The new width of the window
43- width : int ,
43+ pub width : int ,
4444 /// The new height of the window
45- height : int
45+ pub height : int
4646 } ,
4747 /// The window lost the focus
4848 LostFocus ,
@@ -51,67 +51,67 @@ pub enum Event {
5151 /// A character was entered
5252 TextEntered {
5353 /// The character entered by the user
54- code : char
54+ pub code : char
5555 } ,
5656 /// A key was pressed
5757 KeyPressed {
5858 /// The pressed key
59- code : Key ,
59+ pub code : Key ,
6060 /// Is alt pressed too?
61- alt : bool ,
61+ pub alt : bool ,
6262 /// Is ctrl pressed too?
63- ctrl : bool ,
63+ pub ctrl : bool ,
6464 /// Is shift pressed too?
65- shift : bool ,
65+ pub shift : bool ,
6666 /// Is system pressed too?
67- system : bool
67+ pub system : bool
6868 } ,
6969 /// A key was released
7070 KeyReleased {
7171 /// The released key
72- code : Key ,
72+ pub code : Key ,
7373 /// Is alt released too?
74- alt : bool ,
74+ pub alt : bool ,
7575 /// Is ctrl released too?
76- ctrl : bool ,
76+ pub ctrl : bool ,
7777 /// Is shift released too?
78- shift : bool ,
78+ pub shift : bool ,
7979 /// Is system released too?
80- system : bool
80+ pub system : bool
8181 } ,
8282 /// The mouse wheel was scrolled
8383 MouseWheelMoved {
8484 /// Number of ticks the wheel has moved (positive is up, negative is down)
85- delta : int ,
85+ pub delta : int ,
8686 /// X position of the mouse pointer, relative to the left of the owner window.
87- x : int ,
87+ pub x : int ,
8888 /// Y position of the mouse pointer, relative to the top of the owner window.
89- y : int
89+ pub y : int
9090 } ,
9191 /// A mouse button was pressed
9292 MouseButtonPressed {
9393 /// Code of the button that has been pressed.
94- button : MouseButton ,
94+ pub button : MouseButton ,
9595 /// X position of the mouse pointer, relative to the left of the owner window.
96- x : int ,
96+ pub x : int ,
9797 /// Y position of the mouse pointer, relative to the top of the owner window.
98- y : int
98+ pub y : int
9999 } ,
100100 /// A mouse button was released
101101 MouseButtonReleased {
102102 /// Code of the button that has been pressed.
103- button : MouseButton ,
103+ pub button : MouseButton ,
104104 /// X position of the mouse pointer, relative to the left of the owner window.
105- x : int ,
105+ pub x : int ,
106106 /// Y position of the mouse pointer, relative to the top of the owner window.
107- y : int
107+ pub y : int
108108 } ,
109109 /// The mouse cursor moved
110110 MouseMoved {
111111 /// X position of the mouse pointer, relative to the left of the owner window.
112- x : int ,
112+ pub x : int ,
113113 /// Y position of the mouse pointer, relative to the top of the owner window.
114- y : int
114+ pub y : int
115115 } ,
116116 /// The mouse cursor entered the area of the window
117117 MouseEntered ,
@@ -120,35 +120,35 @@ pub enum Event {
120120 /// A joystick button was pressed
121121 JoystickButtonPressed {
122122 /// Index of the joystick (in range [0 .. joystick::Count - 1])
123- joystickid : int ,
123+ pub joystickid : int ,
124124 /// Index of the button that has been pressed (in range [0 .. Joystick::button_count - 1])
125- button : int
125+ pub button : int
126126 } ,
127127 /// A joystick button was released
128128 JoystickButtonReleased {
129129 /// Index of the joystick (in range [0 .. joystick::Count - 1])
130- joystickid : int ,
130+ pub joystickid : int ,
131131 /// Index of the button that has been pressed (in range [0 .. Joystick::button_count - 1])
132- button : int
132+ pub button : int
133133 } ,
134134 /// The joystick moved along an axis
135135 JoystickMoved {
136136 /// Index of the joystick (in range [0 .. joystick::Count - 1])
137- joystickid : uint ,
137+ pub joystickid : uint ,
138138 /// Axis on which the joystick moved.
139- axis : Axis ,
139+ pub axis : Axis ,
140140 /// New position on the axis (in range [-100 .. 100])
141- position : f32
141+ pub position : f32
142142 } ,
143143 /// A joystick was connected
144144 JoystickConnected {
145145 /// Index of the joystick (in range [0 .. joystick::Count - 1])
146- joystickid : uint
146+ pub joystickid : uint
147147 } ,
148148 /// A joystick was disconnected
149149 JoystickDisconnected {
150150 /// Index of the joystick (in range [0 .. joystick::Count - 1])
151- joystickid : uint
151+ pub joystickid : uint
152152 } ,
153153 /// No Event
154154 NoEvent
0 commit comments