gosu 0.7.27 → 0.7.27.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,7 @@ namespace Gosu
8
8
  //! mouse buttons and mouse wheel (ms*) and gamepad buttons (gp*).
9
9
  enum ButtonName
10
10
  {
11
- kbRangeBegin = 0x01,
11
+ kbRangeBegin = 0x00,
12
12
  kbEscape = 0x35,
13
13
  kbF1 = 0x7a,
14
14
  kbF2 = 0x78,
@@ -8,7 +8,7 @@ namespace Gosu
8
8
  //! mouse buttons and mouse wheel (ms*) and gamepad buttons (gp*).
9
9
  enum ButtonName
10
10
  {
11
- kbRangeBegin = 1,
11
+ kbRangeBegin = 0x00,
12
12
  kbEscape = 0x01,
13
13
  kbF1 = 0x3b,
14
14
  kbF2 = 0x3c,
@@ -8,7 +8,7 @@ namespace Gosu
8
8
  //! mouse buttons and mouse wheel (ms*) and gamepad buttons (gp*).
9
9
  enum ButtonName
10
10
  {
11
- kbRangeBegin = 0x01,
11
+ kbRangeBegin = 0x00,
12
12
  kbA = 'a',
13
13
  kbB = 'b',
14
14
  kbC = 'c',
@@ -4,6 +4,6 @@
4
4
  #define GOSU_MAJOR_VERSION 0
5
5
  #define GOSU_MINOR_VERSION 7
6
6
  #define GOSU_POINT_VERSION 27
7
- #define GOSU_VERSION "0.7.27"
7
+ #define GOSU_VERSION "0.7.27.1"
8
8
 
9
9
  #endif
@@ -313,5 +313,5 @@ Gosu::Song::Song(Audio& audio, const std::wstring& filename)
313
313
 
314
314
  Gosu::Song::Song(Audio& audio, Type type, Reader reader)
315
315
  {
316
- Song(type, reader).data.swap(data);
316
+ Song(reader).data.swap(data);
317
317
  }
@@ -10982,7 +10982,7 @@ SWIGEXPORT void Init_gosu(void) {
10982
10982
  rb_define_const(mGosu, "MAJOR_VERSION", SWIG_From_int(static_cast< int >(0)));
10983
10983
  rb_define_const(mGosu, "MINOR_VERSION", SWIG_From_int(static_cast< int >(7)));
10984
10984
  rb_define_const(mGosu, "POINT_VERSION", SWIG_From_int(static_cast< int >(27)));
10985
- rb_define_const(mGosu, "VERSION", SWIG_FromCharPtr("0.7.27"));
10985
+ rb_define_const(mGosu, "VERSION", SWIG_FromCharPtr("0.7.27.1"));
10986
10986
  rb_define_module_function(mGosu, "milliseconds", VALUEFUNC(_wrap_milliseconds), -1);
10987
10987
  rb_define_module_function(mGosu, "random", VALUEFUNC(_wrap_random), -1);
10988
10988
  rb_define_module_function(mGosu, "degrees_to_radians", VALUEFUNC(_wrap_degrees_to_radians), -1);
@@ -160,12 +160,12 @@ struct Gosu::Window::Impl
160
160
 
161
161
  if (showingCursor && !window->needsCursor())
162
162
  {
163
- XUndefineCursor(display, this->window);
163
+ XDefineCursor(display, this->window, emptyCursor);
164
164
  showingCursor = false;
165
165
  }
166
166
  else if (!showingCursor && window->needsCursor())
167
167
  {
168
- XDefineCursor(display, this->window, emptyCursor);
168
+ XUndefineCursor(display, this->window);
169
169
  showingCursor = true;
170
170
  }
171
171
 
@@ -1,8 +1,9 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- if defined? RUBY_PLATFORM and (RUBY_PLATFORM['-win32'] or RUBY_PLATFORM['win32-'] or RUBY_PLATFORM['mswin'] or RUBY_PLATFORM['mingw32']) then
4
- puts 'This gem is not meant to be installed on Windows. If you see this message, gem made a mistake.'
5
- puts 'On Windows, please use:'
3
+ WINDOWS_HINTS = %w(-win32 win32- mswin mingw32)
4
+
5
+ if defined? RUBY_PLATFORM and WINDOWS_HINTS.any? { |hint| RUBY_PLATFORM.include? hint } then
6
+ puts 'This gem is not meant to be installed on Windows. Instead, please use:'
6
7
  puts 'gem install gosu --platform=i386-mingw32'
7
8
  exit 1
8
9
  end
@@ -13,36 +14,55 @@ puts 'http://code.google.com/p/gosu/wiki/GettingStartedOnLinux'
13
14
  puts
14
15
 
15
16
  # FIXME should reversely filter out files ending in Win, Mac, Touch, AL etc.
16
- SOURCE_FILES =
17
- %w(Math.cpp Utility.cpp IO.cpp FileUnix.cpp InputX.cpp TextInputX.cpp TimingUnix.cpp WindowX.cpp
18
- Graphics/Bitmap.cpp Graphics/BitmapUtils.cpp Graphics/Color.cpp
19
- Graphics/TexChunk.cpp Graphics/Graphics.cpp Graphics/Image.cpp
20
- Graphics/BlockAllocator.cpp Inspection.cpp
21
- Graphics/Texture.cpp Graphics/LargeImageData.cpp
22
- Graphics/BitmapPNG.cpp Graphics/Font.cpp Graphics/BitmapBMP.cpp
23
- Graphics/TextUnix.cpp Graphics/Text.cpp Graphics/Transform.cpp
24
- Graphics/BitmapColorKey.cpp DirectoriesUnix.cpp
25
- Audio/AudioAudiere.cpp RubyGosu_wrap.cxx)
17
+ SOURCE_FILES = %w(
18
+ Audio/AudioSDL.cpp
19
+ DirectoriesUnix.cpp
20
+ FileUnix.cpp
21
+ Graphics/Bitmap.cpp
22
+ Graphics/BitmapBMP.cpp
23
+ Graphics/BitmapColorKey.cpp
24
+ Graphics/BitmapPNG.cpp
25
+ Graphics/BitmapUtils.cpp
26
+ Graphics/BlockAllocator.cpp
27
+ Graphics/Color.cpp
28
+ Graphics/Font.cpp
29
+ Graphics/Graphics.cpp
30
+ Graphics/Image.cpp
31
+ Graphics/LargeImageData.cpp
32
+ Graphics/TexChunk.cpp
33
+ Graphics/Text.cpp
34
+ Graphics/TextUnix.cpp
35
+ Graphics/Texture.cpp
36
+ Graphics/Transform.cpp
37
+ InputX.cpp
38
+ Inspection.cpp
39
+ IO.cpp
40
+ Math.cpp
41
+ RubyGosu_wrap.cxx
42
+ TextInputX.cpp
43
+ TimingUnix.cpp
44
+ Utility.cpp
45
+ WindowX.cpp
46
+ )
26
47
 
27
48
  require 'mkmf'
28
49
 
29
50
  # Copy all relevant C++ files into the current directory
30
- # FIXME could be done by gem packager
51
+ # FIXME Could be done by gem task instead.
31
52
  SOURCE_FILES.each { |file| `cp ../GosuImpl/#{file} #{File.basename(file)}` }
32
53
 
33
54
  # Symlink our pretty gosu.so into ../lib
34
- # FIXME gosu.rb should just look in the right place
55
+ # FIXME gosu.rb should just look in the right place.
35
56
  `ln -s ../linux/gosu.so ../lib/gosu.so`
36
57
 
37
58
  sdl_config = with_config("sdl-config", "sdl-config")
38
- audiere_config = with_config("audiere-config", "audiere-config")
39
- pango_config = "pkg-config pangoft2" # FIXME should probably use with_config
59
+ pango_config = "pkg-config pangoft2"
40
60
 
41
- $INCFLAGS << " -I../ -I../GosuImpl `#{sdl_config} --cflags` `#{audiere_config} --cxxflags` `#{pango_config} --cflags`"
42
- $LDFLAGS << " `#{sdl_config} --libs` `#{audiere_config} --libs` `#{pango_config} --libs` -lX11"
61
+ $INCFLAGS << " -I../ -I../GosuImpl `#{sdl_config} --cflags` `#{pango_config} --cflags`"
62
+ $LDFLAGS << " `#{sdl_config} --libs` `#{pango_config} --libs` -lX11"
63
+ have_header('SDL_mixer.h') if have_library('SDL_mixer', 'Mix_OpenAudio')
43
64
  have_header('SDL_ttf.h') if have_library('SDL_ttf', 'TTF_RenderUTF8_Blended')
44
65
  have_header('gl.h') if have_library('GL', 'glMatrixMode')
45
66
  have_header('png.h') if have_library('png', 'png_sig_cmp')
46
67
 
47
68
  create_makefile("gosu")
48
-
metadata CHANGED
@@ -1,13 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gosu
3
3
  version: !ruby/object:Gem::Version
4
- hash: 53
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 7
9
9
  - 27
10
- version: 0.7.27
10
+ - 1
11
+ version: 0.7.27.1
11
12
  platform: ruby
12
13
  authors:
13
14
  - Julian Raschke
@@ -16,7 +17,7 @@ autorequire:
16
17
  bindir: bin
17
18
  cert_chain: []
18
19
 
19
- date: 2011-01-29 00:00:00 +08:00
20
+ date: 2011-02-07 00:00:00 +08:00
20
21
  default_executable:
21
22
  dependencies: []
22
23