mirror of
https://github.com/gwm17/glfw.git
synced 2024-11-26 20:28:49 -05:00
Merge branch 'master' into multi-display-support
This commit is contained in:
commit
8e89fff792
|
@ -287,6 +287,7 @@ version of GLFW.</p>
|
||||||
<li>Changed buffer bit depth parameters of <code>glfwOpenWindow</code> to window hints</li>
|
<li>Changed buffer bit depth parameters of <code>glfwOpenWindow</code> to window hints</li>
|
||||||
<li>Renamed <code>glfw.h</code> to <code>glfw3.h</code> to avoid conflicts with 2.x series</li>
|
<li>Renamed <code>glfw.h</code> to <code>glfw3.h</code> to avoid conflicts with 2.x series</li>
|
||||||
<li>Renamed <code>GLFW_WINDOW</code> token to <code>GLFW_WINDOWED</code></li>
|
<li>Renamed <code>GLFW_WINDOW</code> token to <code>GLFW_WINDOWED</code></li>
|
||||||
|
<li>Renamed <code>version</code> test to <code>glfwinfo</code></li>
|
||||||
<li>Replaced ad hoc build system with CMake</li>
|
<li>Replaced ad hoc build system with CMake</li>
|
||||||
<li>Replaced layout-dependent key codes with single, platform-independent set based on US layout</li>
|
<li>Replaced layout-dependent key codes with single, platform-independent set based on US layout</li>
|
||||||
<li>Replaced mouse wheel interface with two-dimensional scrolling interface</li>
|
<li>Replaced mouse wheel interface with two-dimensional scrolling interface</li>
|
||||||
|
@ -302,7 +303,7 @@ version of GLFW.</p>
|
||||||
<li>Removed <code>GLFW_OPENED</code> window parameter</li>
|
<li>Removed <code>GLFW_OPENED</code> window parameter</li>
|
||||||
<li>Removed nonsensical key actions for Unicode character input</li>
|
<li>Removed nonsensical key actions for Unicode character input</li>
|
||||||
<li>Removed <code>GLFWCALL</code> and <code>GLFWAPIENTRY</code> macros for stdcall calling convention</li>
|
<li>Removed <code>GLFWCALL</code> and <code>GLFWAPIENTRY</code> macros for stdcall calling convention</li>
|
||||||
<li>Bugfix: The default OpenGL version in the <code>version</code> test was set to 1.1</li>
|
<li>Bugfix: The default OpenGL version in the <code>glfwinfo</code> test was set to 1.1</li>
|
||||||
<li>Bugfix: The OpenGL profile and forward-compatibility window parameters were not saved after context creation</li>
|
<li>Bugfix: The OpenGL profile and forward-compatibility window parameters were not saved after context creation</li>
|
||||||
<li>Bugfix: The FSAA test did not check for the availability of <code>GL_ARB_multisample</code></li>
|
<li>Bugfix: The FSAA test did not check for the availability of <code>GL_ARB_multisample</code></li>
|
||||||
<li>[Cocoa] Added support for OpenGL 3.2 core profile in 10.7 Lion and above</li>
|
<li>[Cocoa] Added support for OpenGL 3.2 core profile in 10.7 Lion and above</li>
|
||||||
|
|
|
@ -152,6 +152,7 @@ GLFWAPI void glfwEnable(GLFWwindow window, int token)
|
||||||
enableKeyRepeat(window);
|
enableKeyRepeat(window);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
_glfwSetError(GLFW_INVALID_ENUM, NULL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -184,6 +185,7 @@ GLFWAPI void glfwDisable(GLFWwindow window, int token)
|
||||||
disableKeyRepeat(window);
|
disableKeyRepeat(window);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
_glfwSetError(GLFW_INVALID_ENUM, NULL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,7 +53,7 @@ GLFWAPI int glfwGetKey(GLFWwindow handle, int key)
|
||||||
if (key < 0 || key > GLFW_KEY_LAST)
|
if (key < 0 || key > GLFW_KEY_LAST)
|
||||||
{
|
{
|
||||||
// TODO: Decide whether key is a value or enum
|
// TODO: Decide whether key is a value or enum
|
||||||
_glfwSetError(GLFW_INVALID_VALUE,
|
_glfwSetError(GLFW_INVALID_ENUM,
|
||||||
"glfwGetKey: The specified key is invalid");
|
"glfwGetKey: The specified key is invalid");
|
||||||
return GLFW_RELEASE;
|
return GLFW_RELEASE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -345,6 +345,7 @@ GLboolean _glfwIsValidContextConfig(_GLFWwndconfig* wndconfig)
|
||||||
return GL_TRUE;
|
return GL_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Checks whether the specified context fulfils the requirements
|
// Checks whether the specified context fulfils the requirements
|
||||||
// It blames glfwOpenWindow because that's the only caller
|
// It blames glfwOpenWindow because that's the only caller
|
||||||
|
|
10
src/window.c
10
src/window.c
|
@ -468,6 +468,7 @@ GLFWAPI void glfwOpenWindowHint(int target, int hint)
|
||||||
_glfwLibrary.hints.glRobustness = hint;
|
_glfwLibrary.hints.glRobustness = hint;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
_glfwSetError(GLFW_INVALID_ENUM, NULL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -748,12 +749,10 @@ GLFWAPI int glfwGetWindowParam(GLFWwindow handle, int param)
|
||||||
return window->glProfile;
|
return window->glProfile;
|
||||||
case GLFW_OPENGL_ROBUSTNESS:
|
case GLFW_OPENGL_ROBUSTNESS:
|
||||||
return window->glRobustness;
|
return window->glRobustness;
|
||||||
default:
|
|
||||||
_glfwSetError(GLFW_INVALID_ENUM,
|
|
||||||
"glfwGetWindowParam: Invalid enum value for 'param' "
|
|
||||||
"parameter");
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
_glfwSetError(GLFW_INVALID_ENUM, NULL);
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -818,6 +817,7 @@ GLFWAPI void glfwSetWindowSizeCallback(GLFWwindowsizefun cbfun)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Set callback function for window close events
|
// Set callback function for window close events
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
|
|
@ -48,6 +48,7 @@ void _glfwPlatformEnableSystemKeys(_GLFWwindow* window)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Disable system keys
|
// Disable system keys
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
|
|
@ -206,6 +206,7 @@ static GLboolean hasEWMH(_GLFWwindow* window)
|
||||||
return GL_TRUE;
|
return GL_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Translates an X Window key to internal coding
|
// Translates an X Window key to internal coding
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
@ -974,6 +975,7 @@ static void enterFullscreenMode(_GLFWwindow* window)
|
||||||
window->width / 2, window->height / 2);
|
window->width / 2, window->height / 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Leave fullscreen mode
|
// Leave fullscreen mode
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
|
|
@ -16,12 +16,12 @@ add_executable(events events.c)
|
||||||
add_executable(fsaa fsaa.c getopt.c)
|
add_executable(fsaa fsaa.c getopt.c)
|
||||||
add_executable(fsfocus fsfocus.c)
|
add_executable(fsfocus fsfocus.c)
|
||||||
add_executable(gamma gamma.c getopt.c)
|
add_executable(gamma gamma.c getopt.c)
|
||||||
|
add_executable(glfwinfo glfwinfo.c getopt.c)
|
||||||
add_executable(iconify iconify.c getopt.c)
|
add_executable(iconify iconify.c getopt.c)
|
||||||
add_executable(joysticks joysticks.c)
|
add_executable(joysticks joysticks.c)
|
||||||
add_executable(listmodes listmodes.c)
|
add_executable(listmodes listmodes.c)
|
||||||
add_executable(peter peter.c)
|
add_executable(peter peter.c)
|
||||||
add_executable(reopen reopen.c)
|
add_executable(reopen reopen.c)
|
||||||
add_executable(version version.c getopt.c)
|
|
||||||
|
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
# Set fancy names for bundles
|
# Set fancy names for bundles
|
||||||
|
@ -38,8 +38,8 @@ else()
|
||||||
endif(APPLE)
|
endif(APPLE)
|
||||||
|
|
||||||
set(WINDOWS_BINARIES accuracy sharing tearing windows)
|
set(WINDOWS_BINARIES accuracy sharing tearing windows)
|
||||||
set(CONSOLE_BINARIES defaults events fsaa fsfocus gamma iconify joysticks
|
set(CONSOLE_BINARIES defaults events fsaa fsfocus gamma glfwinfo iconify
|
||||||
listmodes peter reopen version)
|
joysticks listmodes peter reopen)
|
||||||
|
|
||||||
if(MSVC)
|
if(MSVC)
|
||||||
# Tell MSVC to use main instead of WinMain for Windows subsystem executables
|
# Tell MSVC to use main instead of WinMain for Windows subsystem executables
|
||||||
|
|
Loading…
Reference in New Issue
Block a user