axmol/cocos/ui/UIWebViewImpl-android.cpp

463 lines
17 KiB
C++
Raw Normal View History

/****************************************************************************
Copyright (c) 2014 Chukong Technologies Inc.
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/
2014-08-25 14:01:18 +08:00
Squashed commit of the following: commit b9181ae92541d11119bedd766773ddb01f0bb486 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 09:34:40 2014 -0700 Compiles luasocket on Mac commit 91fc79aa2101867fedfbcd7d846e9508009894e6 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 09:12:30 2014 -0700 disables luasockets commit 31f2ee462708ab7b604b9399eaabd275e2da9e02 Merge: 19099fd 0abe4cb Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 08:10:48 2014 -0700 Merge remote-tracking branch 'cocos2d/v3' into cmakefile_mac_osx Conflicts: cocos/3d/cocos3d.h commit 19099fd021b4ecf1f2eebd73ea14e84572d1ee33 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 23:21:03 2014 -0700 compiles on Linux commit eec7b92817ac9208123468bb882612aad89f94bf Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 23:16:46 2014 -0700 all projecs compiles with CMake commit 40fcc8325b409a580fdbf26d2ee27aa2d1db0109 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 21:47:27 2014 -0700 CCUserDefualt.mm better includes commit 30709ec8243562858498cb118240bb45bf9b33b0 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 21:26:36 2014 -0700 cpp-tests compiles and works on Mac using CMake commit 67f0fc8df887d08d3d7a27c5fdadd335d6841676 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 20:12:09 2014 -0700 Adds missing files to CMakeLists.txt commit 36f939ea7f157ca851aee138300c13d9888c0078 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 19:52:34 2014 -0700 Adds more box2d missing files commit 00f81e3b5ec97150974cc6022e86c394ff488ccb Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 19:39:54 2014 -0700 Adds missing box2d files commit 9673227b4d7d0e6d9eced49bdd69b98cb519968a Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 18:44:15 2014 -0700 Initial CMake support for Mac
2014-09-10 03:18:31 +08:00
#ifdef __ANDROID__
2014-09-10 07:50:02 +08:00
#include "UIWebViewImpl-android.h"
2014-08-26 16:53:37 +08:00
#include <unordered_map>
#include <stdlib.h>
#include <string>
2014-08-25 14:01:18 +08:00
#include "jni/JniHelper.h"
#include <jni.h>
2014-08-26 16:53:37 +08:00
2014-08-29 11:28:28 +08:00
#include "UIWebView.h"
2014-08-25 14:01:18 +08:00
#include "platform/CCGLView.h"
#include "base/CCDirector.h"
#include "platform/CCFileUtils.h"
#include "ui/UIHelper.h"
2014-08-25 14:01:18 +08:00
#define CLASS_NAME "org/cocos2dx/lib/Cocos2dxWebViewHelper"
2014-08-26 16:53:37 +08:00
#define LOGD(...) __android_log_print(ANDROID_LOG_DEBUG,"",__VA_ARGS__)
static const std::string s_defaultBaseUrl = "file:///android_asset/";
static const std::string s_sdRootBaseUrl = "file://";
2015-10-15 21:43:53 +08:00
static std::string getFixedBaseUrl(const std::string& baseUrl)
{
std::string fixedBaseUrl;
if (baseUrl.empty())
{
fixedBaseUrl = s_defaultBaseUrl;
}
else if (baseUrl.find(s_sdRootBaseUrl) != std::string::npos)
{
fixedBaseUrl = baseUrl;
}
else if (baseUrl.c_str()[0] != '/') {
if(baseUrl.find("assets/") == 0) {
fixedBaseUrl = s_defaultBaseUrl + baseUrl.c_str()[7];
}
else {
fixedBaseUrl = s_defaultBaseUrl + baseUrl;
}
}
else {
fixedBaseUrl = s_sdRootBaseUrl + baseUrl;
}
if (fixedBaseUrl.c_str()[fixedBaseUrl.length() - 1] != '/') {
fixedBaseUrl += "/";
}
return fixedBaseUrl;
}
2014-08-26 16:53:37 +08:00
extern "C" {
/*
* Class: org_cocos2dx_lib_Cocos2dxWebViewHelper
* Method: shouldStartLoading
* Signature: (ILjava/lang/String;)Z
*/
JNIEXPORT jboolean JNICALL Java_org_cocos2dx_lib_Cocos2dxWebViewHelper_shouldStartLoading(JNIEnv *env, jclass, jint index, jstring jurl) {
auto charUrl = env->GetStringUTFChars(jurl, NULL);
std::string url = charUrl;
env->ReleaseStringUTFChars(jurl, charUrl);
return cocos2d::experimental::ui::WebViewImpl::shouldStartLoading(index, url);
}
/*
* Class: org_cocos2dx_lib_Cocos2dxWebViewHelper
* Method: didFinishLoading
* Signature: (ILjava/lang/String;)V
*/
JNIEXPORT void JNICALL Java_org_cocos2dx_lib_Cocos2dxWebViewHelper_didFinishLoading(JNIEnv *env, jclass, jint index, jstring jurl) {
2014-08-26 16:53:37 +08:00
// LOGD("didFinishLoading");
auto charUrl = env->GetStringUTFChars(jurl, NULL);
std::string url = charUrl;
env->ReleaseStringUTFChars(jurl, charUrl);
cocos2d::experimental::ui::WebViewImpl::didFinishLoading(index, url);
}
/*
* Class: org_cocos2dx_lib_Cocos2dxWebViewHelper
* Method: didFailLoading
* Signature: (ILjava/lang/String;)V
*/
JNIEXPORT void JNICALL Java_org_cocos2dx_lib_Cocos2dxWebViewHelper_didFailLoading(JNIEnv *env, jclass, jint index, jstring jurl) {
2014-08-26 16:53:37 +08:00
// LOGD("didFailLoading");
auto charUrl = env->GetStringUTFChars(jurl, NULL);
std::string url = charUrl;
env->ReleaseStringUTFChars(jurl, charUrl);
cocos2d::experimental::ui::WebViewImpl::didFailLoading(index, url);
}
/*
* Class: org_cocos2dx_lib_Cocos2dxWebViewHelper
* Method: onJsCallback
* Signature: (ILjava/lang/String;)V
*/
JNIEXPORT void JNICALL Java_org_cocos2dx_lib_Cocos2dxWebViewHelper_onJsCallback(JNIEnv *env, jclass, jint index, jstring jmessage) {
2014-08-26 16:53:37 +08:00
// LOGD("jsCallback");
auto charMessage = env->GetStringUTFChars(jmessage, NULL);
std::string message = charMessage;
env->ReleaseStringUTFChars(jmessage, charMessage);
cocos2d::experimental::ui::WebViewImpl::onJsCallback(index, message);
}
}
2014-08-25 14:01:18 +08:00
namespace {
2014-08-25 14:01:18 +08:00
int createWebViewJNI() {
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "createWebView", "()I")) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
jint viewTag = t.env->CallStaticIntMethod(t.classID, t.methodID);
t.env->DeleteLocalRef(t.classID);
return viewTag;
}
return -1;
}
void removeWebViewJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "removeWebView", "(I)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
}
}
void setWebViewRectJNI(const int index, const int left, const int top, const int width, const int height) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "setWebViewRect", "(IIIII)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, left, top, width, height);
t.env->DeleteLocalRef(t.classID);
}
}
void setJavascriptInterfaceSchemeJNI(const int index, const std::string &scheme) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "setJavascriptInterfaceScheme", "(ILjava/lang/String;)V")) {
jstring jScheme = t.env->NewStringUTF(scheme.c_str());
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jScheme);
t.env->DeleteLocalRef(jScheme);
t.env->DeleteLocalRef(t.classID);
}
}
void loadDataJNI(const int index, const std::string &data, const std::string &MIMEType, const std::string &encoding, const std::string &baseURL) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "loadData", "(ILjava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V")) {
jstring jData = t.env->NewStringUTF(data.c_str());
jstring jMIMEType = t.env->NewStringUTF(MIMEType.c_str());
jstring jEncoding = t.env->NewStringUTF(encoding.c_str());
jstring jBaseURL = t.env->NewStringUTF(getFixedBaseUrl(baseURL).c_str());
2014-08-25 14:01:18 +08:00
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jData, jMIMEType, jEncoding, jBaseURL);
t.env->DeleteLocalRef(jData);
t.env->DeleteLocalRef(jMIMEType);
t.env->DeleteLocalRef(jEncoding);
t.env->DeleteLocalRef(jBaseURL);
t.env->DeleteLocalRef(t.classID);
}
}
void loadHTMLStringJNI(const int index, const std::string &string, const std::string &baseURL) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "loadHTMLString", "(ILjava/lang/String;Ljava/lang/String;)V")) {
2014-08-25 14:01:18 +08:00
jstring jString = t.env->NewStringUTF(string.c_str());
jstring jBaseURL = t.env->NewStringUTF(getFixedBaseUrl(baseURL).c_str());
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jString, jBaseURL);
2014-08-25 14:01:18 +08:00
t.env->DeleteLocalRef(jString);
t.env->DeleteLocalRef(jBaseURL);
t.env->DeleteLocalRef(t.classID);
}
}
void loadUrlJNI(const int index, const std::string &url) {
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "loadUrl", "(ILjava/lang/String;)V")) {
jstring jUrl = t.env->NewStringUTF(url.c_str());
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jUrl);
t.env->DeleteLocalRef(jUrl);
t.env->DeleteLocalRef(t.classID);
}
}
void loadFileJNI(const int index, const std::string &filePath) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "loadFile", "(ILjava/lang/String;)V")) {
jstring jFilePath = t.env->NewStringUTF(filePath.c_str());
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jFilePath);
t.env->DeleteLocalRef(jFilePath);
t.env->DeleteLocalRef(t.classID);
}
}
void stopLoadingJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "stopLoading", "(I)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
}
}
void reloadJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "reload", "(I)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
}
}
bool canGoBackJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "canGoBack", "(I)Z")) {
jboolean ret = t.env->CallStaticBooleanMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
return ret;
}
return false;
}
bool canGoForwardJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "canGoForward", "(I)Z")) {
jboolean ret = t.env->CallStaticBooleanMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
return ret;
}
return false;
}
void goBackJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "goBack", "(I)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
}
}
void goForwardJNI(const int index) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "goForward", "(I)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index);
t.env->DeleteLocalRef(t.classID);
}
}
void evaluateJSJNI(const int index, const std::string &js) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "evaluateJS", "(ILjava/lang/String;)V")) {
jstring jjs = t.env->NewStringUTF(js.c_str());
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, jjs);
t.env->DeleteLocalRef(jjs);
t.env->DeleteLocalRef(t.classID);
}
}
void setScalesPageToFitJNI(const int index, const bool scalesPageToFit) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "setScalesPageToFit", "(IZ)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, scalesPageToFit);
t.env->DeleteLocalRef(t.classID);
}
}
void setWebViewVisibleJNI(const int index, const bool visible) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
cocos2d::JniMethodInfo t;
if (cocos2d::JniHelper::getStaticMethodInfo(t, CLASS_NAME, "setVisible", "(IZ)V")) {
t.env->CallStaticVoidMethod(t.classID, t.methodID, index, visible);
t.env->DeleteLocalRef(t.classID);
}
}
std::string getUrlStringByFileName(const std::string &fileName) {
2014-08-26 16:53:37 +08:00
// LOGD("error: %s,%d",__func__,__LINE__);
2014-08-25 14:01:18 +08:00
const std::string basePath("file:///android_asset/");
std::string fullPath = cocos2d::FileUtils::getInstance()->fullPathForFilename(fileName);
const std::string assetsPath("assets/");
std::string urlString;
if (fullPath.find(assetsPath) != std::string::npos) {
urlString = fullPath.replace(fullPath.find_first_of(assetsPath), assetsPath.length(), basePath);
} else {
urlString = fullPath;
}
return urlString;
}
} // namespace
namespace cocos2d {
namespace experimental {
namespace ui{
static std::unordered_map<int, cocos2d::experimental::ui::WebViewImpl*> s_WebViewImpls;
WebViewImpl::WebViewImpl(WebView *webView) : _viewTag(-1), _webView(webView) {
_viewTag = createWebViewJNI();
s_WebViewImpls[_viewTag] = this;
}
WebViewImpl::~WebViewImpl() {
removeWebViewJNI(_viewTag);
s_WebViewImpls.erase(_viewTag);
}
void WebViewImpl::loadData(const Data &data, const std::string &MIMEType, const std::string &encoding, const std::string &baseURL) {
std::string dataString(reinterpret_cast<char *>(data.getBytes()), static_cast<unsigned int>(data.getSize()));
loadDataJNI(_viewTag, dataString, MIMEType, encoding, baseURL);
}
void WebViewImpl::loadHTMLString(const std::string &string, const std::string &baseURL) {
loadHTMLStringJNI(_viewTag, string, baseURL);
}
2014-09-15 18:14:04 +08:00
void WebViewImpl::loadURL(const std::string &url) {
loadUrlJNI(_viewTag, url);
}
void WebViewImpl::loadFile(const std::string &fileName) {
auto fullPath = getUrlStringByFileName(fileName);
loadFileJNI(_viewTag, fullPath);
}
void WebViewImpl::stopLoading() {
stopLoadingJNI(_viewTag);
}
void WebViewImpl::reload() {
reloadJNI(_viewTag);
}
bool WebViewImpl::canGoBack() {
return canGoBackJNI(_viewTag);
}
bool WebViewImpl::canGoForward() {
return canGoForwardJNI(_viewTag);
}
void WebViewImpl::goBack() {
goBackJNI(_viewTag);
}
void WebViewImpl::goForward() {
goForwardJNI(_viewTag);
}
void WebViewImpl::setJavascriptInterfaceScheme(const std::string &scheme) {
setJavascriptInterfaceSchemeJNI(_viewTag, scheme);
}
void WebViewImpl::evaluateJS(const std::string &js) {
evaluateJSJNI(_viewTag, js);
}
void WebViewImpl::setScalesPageToFit(const bool scalesPageToFit) {
setScalesPageToFitJNI(_viewTag, scalesPageToFit);
}
bool WebViewImpl::shouldStartLoading(const int viewTag, const std::string &url) {
2015-10-15 21:43:53 +08:00
bool allowLoad = true;
auto it = s_WebViewImpls.find(viewTag);
if (it != s_WebViewImpls.end()) {
auto webView = it->second->_webView;
if (webView->_onShouldStartLoading) {
allowLoad = webView->_onShouldStartLoading(webView, url);
}
}
2015-10-15 21:43:53 +08:00
return allowLoad;
}
void WebViewImpl::didFinishLoading(const int viewTag, const std::string &url){
auto it = s_WebViewImpls.find(viewTag);
if (it != s_WebViewImpls.end()) {
auto webView = it->second->_webView;
if (webView->_onDidFinishLoading) {
webView->_onDidFinishLoading(webView, url);
}
}
}
void WebViewImpl::didFailLoading(const int viewTag, const std::string &url){
auto it = s_WebViewImpls.find(viewTag);
if (it != s_WebViewImpls.end()) {
auto webView = it->second->_webView;
if (webView->_onDidFailLoading) {
webView->_onDidFailLoading(webView, url);
}
}
}
void WebViewImpl::onJsCallback(const int viewTag, const std::string &message){
auto it = s_WebViewImpls.find(viewTag);
if (it != s_WebViewImpls.end()) {
auto webView = it->second->_webView;
if (webView->_onJSCallback) {
webView->_onJSCallback(webView, message);
}
}
}
void WebViewImpl::draw(cocos2d::Renderer *renderer, cocos2d::Mat4 const &transform, uint32_t flags) {
if (flags & cocos2d::Node::FLAGS_TRANSFORM_DIRTY) {
auto uiRect = cocos2d::ui::Helper::convertBoundingBoxToScreen(_webView);
setWebViewRectJNI(_viewTag, uiRect.origin.x, uiRect.origin.y,
uiRect.size.width, uiRect.size.height);
}
}
void WebViewImpl::setVisible(bool visible) {
setWebViewVisibleJNI(_viewTag, visible);
}
2014-08-26 16:53:37 +08:00
} // namespace ui
} // namespace experimental
2014-08-26 16:53:37 +08:00
} //namespace cocos2d
Squashed commit of the following: commit b9181ae92541d11119bedd766773ddb01f0bb486 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 09:34:40 2014 -0700 Compiles luasocket on Mac commit 91fc79aa2101867fedfbcd7d846e9508009894e6 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 09:12:30 2014 -0700 disables luasockets commit 31f2ee462708ab7b604b9399eaabd275e2da9e02 Merge: 19099fd 0abe4cb Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Tue Sep 9 08:10:48 2014 -0700 Merge remote-tracking branch 'cocos2d/v3' into cmakefile_mac_osx Conflicts: cocos/3d/cocos3d.h commit 19099fd021b4ecf1f2eebd73ea14e84572d1ee33 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 23:21:03 2014 -0700 compiles on Linux commit eec7b92817ac9208123468bb882612aad89f94bf Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 23:16:46 2014 -0700 all projecs compiles with CMake commit 40fcc8325b409a580fdbf26d2ee27aa2d1db0109 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 21:47:27 2014 -0700 CCUserDefualt.mm better includes commit 30709ec8243562858498cb118240bb45bf9b33b0 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 21:26:36 2014 -0700 cpp-tests compiles and works on Mac using CMake commit 67f0fc8df887d08d3d7a27c5fdadd335d6841676 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 20:12:09 2014 -0700 Adds missing files to CMakeLists.txt commit 36f939ea7f157ca851aee138300c13d9888c0078 Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 19:52:34 2014 -0700 Adds more box2d missing files commit 00f81e3b5ec97150974cc6022e86c394ff488ccb Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 19:39:54 2014 -0700 Adds missing box2d files commit 9673227b4d7d0e6d9eced49bdd69b98cb519968a Author: Ricardo Quesada <ricardoquesada@gmail.com> Date: Mon Sep 8 18:44:15 2014 -0700 Initial CMake support for Mac
2014-09-10 03:18:31 +08:00
#endif // __ANDROID__