[colobot] 340/390: Merge branch 'ManuelBlanc-dev-osx' into dev
Didier Raboud
odyx at moszumanska.debian.org
Fri Jun 12 14:22:02 UTC 2015
This is an automated email from the git hooks/post-receive script.
odyx pushed a commit to branch upstream/latest
in repository colobot.
commit 6c87144ae844b207ce469c8cde8c1084523ea11f
Merge: 81096fd 56393f4
Author: Piotr Dziwinski <piotrdz at gmail.com>
Date: Tue Apr 28 14:51:53 2015 -0700
Merge branch 'ManuelBlanc-dev-osx' into dev
CMakeLists.txt | 6 +-----
lib/clipboard/CMakeLists.txt | 3 +++
lib/clipboard/src/clipboardOSX.m | 24 ++++++++++++++++++++++++
src/CMakeLists.txt | 4 +++-
src/ui/edit.cpp | 9 +++++++--
5 files changed, 38 insertions(+), 8 deletions(-)
diff --cc CMakeLists.txt
index be9f0b7,e11acf8..33320de
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@@ -275,26 -254,10 +275,22 @@@ include("${colobot_SOURCE_DIR}/cmake/ms
##
+# MSVC specific settings
+##
+set(WINGETOPT 0)
+if(CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
+ message(STATUS "Adding MSVC-specific options")
+
+ set(CBOT_STATIC 1) # only this works for some reason
+ set(USE_SDL_MAIN 1) # fixes SDL_main
+ set(WINGETOPT 1) # use wingetopt library
+endif()
+
+##
# Clipboard support needs X11 libraries
##
- if(PLATFORM_GNU OR PLATFORM_MACOSX)
+ if(PLATFORM_GNU)
find_package(X11 REQUIRED)
- if(PLATFORM_MACOSX)
- # Add the includes for X11
- include_directories("/opt/X11/include")
- endif()
endif()
diff --cc src/CMakeLists.txt
index 84e08a7,5a9e49f..5c2cdb7
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@@ -254,9 -239,10 +255,10 @@@ set(SYSTEM_INCLUDE
${Boost_INCLUDE_DIRS}
${LIBSNDFILE_INCLUDE_DIR}
${LOCALENAME_INCLUDE_DIR}
- ${OPTIONAL_INCLUDE_DIRS}
${CLIPBOARD_INCLUDE_DIR}
${PHYSFS_INCLUDE_PATH}
+ ${LIBINTL_INCLUDE_PATH}
+ ${OPTIONAL_INCLUDES}
)
set(COLOBOT_LOCAL_INCLUDES ${LOCAL_INCLUDES} PARENT_SCOPE)
diff --cc src/ui/edit.cpp
index ba248ac,736a11f..ed8e3c1
--- a/src/ui/edit.cpp
+++ b/src/ui/edit.cpp
@@@ -25,7 -24,11 +25,8 @@@
#include "clipboard/clipboard.h"
-#include "object/robotmain.h"
-
-#include "object/level/parserparam.h"
-
+ #include "common/config.h"
+#include "common/pathman.h"
#include "common/resources/inputstream.h"
#include "common/resources/outputstream.h"
@@@ -300,14 -301,15 +301,18 @@@ bool CEdit::EventProcess(const Event &e
}
}
- if ( event.type == EVENT_KEY_DOWN && m_bFocus )
+ if (event.type == EVENT_KEY_DOWN)
{
- bShift = ((event.kmodState & KEY_MOD(SHIFT)) != 0);
- bControl = ((event.kmodState & KEY_MOD(CTRL)) != 0);
+ bShift = ( (event.kmodState & KEY_MOD(SHIFT) ) != 0 );
+ #if PLATFORM_MACOSX
+ bControl = ( (event.kmodState & KEY_MOD(META) ) != 0);
+ #else
+ bControl = ( (event.kmodState & KEY_MOD(CTRL) ) != 0);
+ #endif
+ }
+ if ( event.type == EVENT_KEY_DOWN && m_bFocus )
+ {
if ( (event.key.key == KEY(x) && !bShift && bControl) ||
(event.key.key == KEY(DELETE) && bShift && !bControl) )
{
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/colobot.git
More information about the Pkg-games-commits
mailing list