From: Mikko Rasa Date: Sun, 12 Oct 2014 14:22:03 +0000 (+0300) Subject: Cosmetic changes X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=0c9df2a54cd38ba14ffc651bc96914614a08db46;p=libs%2Fgui.git Cosmetic changes --- diff --git a/Build b/Build index 75f7884..9580ba6 100644 --- a/Build +++ b/Build @@ -5,12 +5,9 @@ package "mspgui" require "mspcore"; require "sigc++-2.0"; - if_arch "!windows" + if_arch "!windows & !darwin" { - if_arch "!darwin" - { - require "xlib"; - }; + require "xlib"; }; if_arch "windows" { @@ -150,10 +147,7 @@ package "mspgui" program "ev" { source "examples/ev.cpp"; - build_info - { - library "mspgui"; - }; + use "mspgui"; }; source_tarball diff --git a/source/graphics/cgl/glcontext.cpp b/source/graphics/cgl/glcontext.cpp index 7e06d23..8283825 100644 --- a/source/graphics/cgl/glcontext.cpp +++ b/source/graphics/cgl/glcontext.cpp @@ -20,25 +20,25 @@ struct GLContext::Private void GLContext::platform_init(const GLOptions &opts) { vector attribs; - + attribs.push_back(CPF_DEPTH_SIZE); attribs.push_back(1); - + if(opts.alpha) { attribs.push_back(CPF_ALPHA_SIZE); attribs.push_back(1); } - + if(opts.stencil) { attribs.push_back(CPF_STENCIL_SIZE); attribs.push_back(1); } - + if(opts.doublebuffer) attribs.push_back(CPF_DOUBLEBUFFER); - + if(opts.multisample>0) { attribs.push_back(CPF_SAMPLE_BUFFERS); diff --git a/source/graphics/cocoa/display.cpp b/source/graphics/cocoa/display.cpp index c6824b8..9c4aa22 100644 --- a/source/graphics/cocoa/display.cpp +++ b/source/graphics/cocoa/display.cpp @@ -8,7 +8,7 @@ using namespace std; namespace Msp { namespace Graphics { -Display::Display(const std::string &): +Display::Display(const string &): priv(new Private) { static ErrorDialog err_dlg(0); diff --git a/source/graphics/glx/glcontext.cpp b/source/graphics/glx/glcontext.cpp index b3d8ed0..26275a4 100644 --- a/source/graphics/glx/glcontext.cpp +++ b/source/graphics/glx/glcontext.cpp @@ -23,26 +23,26 @@ struct GLContext::Private void GLContext::platform_init(const GLOptions &opts) { vector attribs; - + attribs.push_back(GLX_RGBA); attribs.push_back(GLX_DEPTH_SIZE); attribs.push_back(1); - + if(opts.alpha) { attribs.push_back(GLX_ALPHA_SIZE); attribs.push_back(1); } - + if(opts.stencil) { attribs.push_back(GLX_STENCIL_SIZE); attribs.push_back(1); } - + if(opts.doublebuffer) attribs.push_back(GLX_DOUBLEBUFFER); - + if(opts.multisample>0) { attribs.push_back(GLX_SAMPLE_BUFFERS_ARB); @@ -50,7 +50,7 @@ void GLContext::platform_init(const GLOptions &opts) attribs.push_back(GLX_SAMPLES_ARB); attribs.push_back(opts.multisample); } - + attribs.push_back(0); DisplayHandle dpy = display.get_private().display; diff --git a/source/input/cocoa/keyboard.cpp b/source/input/cocoa/keyboard.cpp index c2cdf35..db097aa 100644 --- a/source/input/cocoa/keyboard.cpp +++ b/source/input/cocoa/keyboard.cpp @@ -27,5 +27,5 @@ void Keyboard::input_event(const Graphics::Window::Event &event) } } -} // namespace Inpus +} // namespace Input } // namespace Msp diff --git a/source/input/cocoa/keys.cpp b/source/input/cocoa/keys.cpp index 7d64398..f8515bb 100644 --- a/source/input/cocoa/keys.cpp +++ b/source/input/cocoa/keys.cpp @@ -3,7 +3,7 @@ namespace Msp { namespace Input { -unsigned sys_keymap[N_KEYS_]= +unsigned sys_keymap[N_KEYS_] = { 0, 0, 0, 0, 0, 0, 0, 0, 8, 9, 10, 0, 0, 0, 0, 0, diff --git a/source/input/windows/keys.cpp b/source/input/windows/keys.cpp index 601146e..e4cd0dc 100644 --- a/source/input/windows/keys.cpp +++ b/source/input/windows/keys.cpp @@ -4,7 +4,7 @@ namespace Msp { namespace Input { -unsigned sys_keymap[N_KEYS_]= +unsigned sys_keymap[N_KEYS_] = { 0, 0, 0, 0, 0, 0, 0, 0, VK_BACK, VK_TAB, VK_RETURN, 0, 0, 0, 0, 0, diff --git a/source/input/x11/keys.cpp b/source/input/x11/keys.cpp index 751c2e2..77cd95d 100644 --- a/source/input/x11/keys.cpp +++ b/source/input/x11/keys.cpp @@ -4,7 +4,7 @@ namespace Msp { namespace Input { -unsigned sys_keymap[N_KEYS_]= +unsigned sys_keymap[N_KEYS_] = { 0, 0, 0, 0, 0, 0, 0, 0, XK_BackSpace, XK_Tab, XK_Return, 0, 0, 0, 0, 0,