uh 1.2.1 → 1.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: eb111523e35ca986f1df0008b339407efb803964
4
- data.tar.gz: a42b77c2d47c94a889990ffaed2229afc97f26d3
3
+ metadata.gz: df7322477a9566e9b60f54a6e00a9facda3e1e30
4
+ data.tar.gz: 5ffd74102f30594a3fa5b9614fde19aa59e3dd7e
5
5
  SHA512:
6
- metadata.gz: 40d6ad54516a7c74a2310dd4efc16041d9c5c4f7a0b00673837f15d842ce27724418d79ade120f28385e7c1ddae3ed0f36132f94c5df6a20627440aafbe2dda0
7
- data.tar.gz: 8a20c4f547461632eaf7a609e805ce43c154045c2e0dd00c535c135a17f8803629b538caadb7882cf50045f01d6d55c34edd82d2d53a00ebe9390f65b78ceed8
6
+ metadata.gz: 0cefb2aaf868437ba37c283d9bb88d49237efd131412e7944b6e88fb04d77181755fe0d2aca2047558a34fd417a9c5f8b7796a157e085d969ebf9f54f62c08b7
7
+ data.tar.gz: 111ec34b1d7781a42dad333cc69c28df8fd85fb8065a8c91b1170f6d883bc5a8b44fee7363240e8f3f1aca7a62c5cf1cbae85658ed4d8563ba6d878ecf6bde3d
data/ext/uh/uh.c CHANGED
@@ -120,6 +120,7 @@ void uh_screen() {
120
120
  void uh_window() {
121
121
  cWindow = rb_define_class_under(mUh, "Window", rb_cObject);
122
122
  rb_define_attr(cWindow, "id", 1, 0);
123
+ rb_define_method(cWindow, "destroy", window_destroy, 0);
123
124
  rb_define_method(cWindow, "focus", window_focus, 0);
124
125
  rb_define_method(cWindow, "kill", window_kill, 0);
125
126
  rb_define_method(cWindow, "map", window_map, 0);
data/ext/uh/uh.h CHANGED
@@ -80,6 +80,7 @@ VALUE pixmap_make(Display *display, Pixmap xpixmap, VALUE width, VALUE height);
80
80
 
81
81
  VALUE screen_init(VALUE self, VALUE id, VALUE x, VALUE y, VALUE w, VALUE h);
82
82
 
83
+ VALUE window_destroy(VALUE self);
83
84
  VALUE window_focus(VALUE self);
84
85
  VALUE window_icccm_wm_delete(VALUE self);
85
86
  VALUE window_icccm_wm_protocols(VALUE self);
data/ext/uh/window.c CHANGED
@@ -9,6 +9,14 @@
9
9
  #define WINDOW window->id
10
10
 
11
11
 
12
+ VALUE window_destroy(VALUE self) {
13
+ SET_WINDOW(self);
14
+
15
+ XDestroyWindow(DPY, WINDOW);
16
+
17
+ return Qnil;
18
+ }
19
+
12
20
  VALUE window_focus(VALUE self) {
13
21
  SET_WINDOW(self);
14
22
 
data/lib/uh/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Uh
2
- VERSION = '1.2.1'.freeze
2
+ VERSION = '1.2.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uh
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thibault Jouan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-16 00:00:00.000000000 Z
11
+ date: 2015-04-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake