Commit Graph

997 Commits

Author SHA1 Message Date
Jare Guo bf7a01bdd5 Merge pull request #1508 from cocos-creator/v2.0-release
sync branch
2018-09-12 14:50:13 +08:00
leda c74745eee4 add "getSafeAreaEdge" interface to get SafeArea edge insets (#1502)
* try to resume iPhone X support

* gen binding code

* only get SafeAreaEdge on native

* add getSafeAreaEdge for others

* update binding-generator
2018-09-10 10:14:23 +08:00
leda 4ca166e109 dispatch show/hide event to js, included "cocos simulator" (#1500)
* add dispatchEnterBackgroundEvent for simulator

* more stable when set canvas size on win32

* add isNan check for float & double

* simplify event dispatch on AppDelegate
2018-09-06 16:39:45 +08:00
Jare Guo 63d7ba61e8 bump to 2.1 and merge commit v2.0-release into develop 2018-09-06 15:33:43 +08:00
W-MTZing d27e5a798c remove log names about cocos (#1496) 2018-09-05 10:51:42 +08:00
CocosRobot f37a259dd8 [ci skip][AUTO]: updating jsbinding automatically (#1495) 2018-09-04 13:53:50 +08:00
wdzhangchukong 21377fdb74 Remove names about Cocos (#1494) 2018-09-04 13:41:02 +08:00
leda 0fb1c97e83 support to save render texture data by "saveImageData " (#1492)
* add jsb.savePixelsToFile to support screenshot

* add return value for
 savePixelsToFile

* rename: savePixelsToFile -> saveImageData
2018-09-03 09:38:52 +08:00
Jare Guo caee68b1ff Merge pull request #1490 from cocos-creator/v2.0-release
sync branch
2018-08-30 15:09:48 +08:00
minggo b642e0fcc7 Merge branch 'v2.0-release-rename' of github.com:cocos-creator/cocos2d-x-lite into merge-rename 2018-08-28 14:39:40 +08:00
wdzhangchukong e00113cfd6 Get jsb by __jsbObj (#1481) 2018-08-27 11:48:22 +08:00
CocosRobot 81301ca4b4 [ci skip][AUTO]: updating jsbinding automatically (#1480) 2018-08-24 20:43:09 +08:00
wdzhangchukong b44c2a68dc Change cocos2dx_auto to jsb (#1479) 2018-08-24 20:26:11 +08:00
CocosRobot 80fdcd0e74 [ci skip][AUTO]: updating jsbinding automatically (#1477) 2018-08-24 17:45:25 +08:00
Vincent Yang 3d2a9017bb [bug] loadImage don't call js callback when input path is invalid (#1478) 2018-08-24 17:42:15 +08:00
wdzhangchukong bf27fdd955 Rename cc in JSB (#1476)
* Rename __ccgl to __gl

* Rename __CCPrivateData to __PrivateData

* Change CanvasRenderingContext2D to global

* Change CanvasRenderingContext2D to global

* Change getDeviceMotionValue into Device

* Change FileUtils to global

* Change AudioEngine to global

* Change AudioEngine into Audio

* Remove cc in c++

* Remove __jsc__

* Change auto file template

* Name jsb_cocos2d_global to auto

* Reset jsb_cocos2dx_auto

* Register jsb_cocos2dx_global_auto
2018-08-24 17:03:50 +08:00
W-MTZing 935a759cf4 rename c++ call java function by macro (#1468) 2018-08-22 14:07:17 +08:00
W-MTZing e284a0efd1 rename jni function by macro (#1467)
* rename jni function by macro

* modify JNI macro name
2018-08-22 09:21:35 +08:00
Jare Guo 548ae4380d Merge branch 'v2.0-release' into next 2018-08-16 14:05:09 +08:00
leda a7f266b9e8 resume View Menu for simulator on mac & win32 (#1456)
* start add menu back

* simulator resume works

* readded scale feature, fix exit bug

* free SetupUI, and fix compile only

* adapt to CustomEvent from struct to class

* resume show/hide FPS feature

* Revert "free SetupUI, and fix compile only"

This reverts commit fd8cf5ca0a17ba62ae5dec46fefea3b58c267c9d.

* Revert "Revert "free SetupUI, and fix compile only""

This reverts commit 6e5934a583db286508d00a61a22e11a3325090f1.

* correct EXIT logic

* scale works

* show/hide fps works

* remove unneed menu, replace tab with space

* remove debug output info

* no need _isShowFPS member

* fix NSError init error
2018-08-16 09:34:47 +08:00
leda 80e102d475 add onResize interface for application on mac & win32 (#1452)
* add resize interface for application

* add dispatchResizeEvent interface

* improve function name, add comments

* add onResize for win32

* directly supply size info when dispatch resize event
2018-08-13 14:30:56 +08:00
leda 0ccc890843 added dispatchKeyboardEvent for android (#1453)
* added dispatchKeyboardEvent for android

* uniform enum class type to uint8
2018-08-13 10:40:23 +08:00
leda 19ab61b252 refine TODO & FIXME flag (#1450)
* change TODO to REFINE

* change REFINE:cjh to REFINE

* change FIXME to IDEA

* improve format
2018-08-10 12:52:00 +08:00
leda 3ea4405d44 add getCurrentStackTrace interface for v8 script engine (#1446)
* add getCurrentStackTrace interface for v8 script engine

* return empty string before script init finished, prevent crash
2018-08-08 18:09:36 +08:00
minggo 1d326a0c1b fix two issues: (#1440)
if return type is string, and return null from java to js, then it will crash
if the parameter is string, and pass null from js to java, then java will get "null" instead of null
2018-08-07 17:19:49 +08:00
W-MTZing 93101a7a0e add loadImage error callback (#1406) (#1436)
* add loadImage error callback

* fix format
2018-08-02 17:28:49 +08:00
yongminghuang 4e206fd656 [bug] Fixed a crash of multiple finger operations (#1433) 2018-08-02 17:27:24 +08:00
minggo b3122ea9e5 add a function to terminate application (#1434) 2018-08-02 10:46:35 +08:00
Jare Guo 625aafbf34 Merge branch 'v2.0-release' into next 2018-07-31 17:27:40 +08:00
leda 9b775e711d fix catch font name error when ttf font name with space (#1423)
* support catch fontName with space when canvas set font

* do same above on android

* improve regex

* add empty loadFont impl for win32 platform

* correct win32 parse font info regex on win32

* add win32 support ttf when font name = font face name

* another space line for win32 platforms

* improve regex when parse font name

* fix regex error

* correct typo
2018-07-26 17:57:25 +08:00
leda a816ffd743 modify android config, use clang (c++_static) to build (#1385)
* correct head file include error

* modify build tool to clang

* remove one useless file include

* remove armeabi files in 2d-x_files
2018-07-25 09:24:29 +08:00
Jare Guo 85c80cd529 Merge pull request #1410 from cocos-creator/v2.0-release
sync branch
2018-07-24 11:46:04 +08:00
leda b3b37cf457 Add AssetsManager to iOS & Mac & Android & win32 (#1405)
* Add incomplete AssetsManager to iOS & Mac

* remove Android.mk refer on Xcode project config

* re-add assetmanager for android

* re-add assetmanager for win32 project config

* remove unused macro define for win32

* remove unused marco define COCOS2D_JAVASCRIPT

* added header include for assetsManager

* Add CCAsyncTaskPool

* Fix AssetsManager event trigger issue

* update win32 project config, added CCAsyncTaskPool

* add CCAsyncTaskPool to extensions Android.mk
2018-07-23 17:50:04 +08:00
W-MTZing 5b407f9fc6 add loadImage error callback (#1406)
* add loadImage error callback

* fix format
2018-07-20 10:59:40 +08:00
wdzhangchukong e41cb4dcc8 Fix crash when param type error (#1390) 2018-07-13 17:07:17 +08:00
minggo e299f74392 fix editbox issue (#1389)
app will crash if missing some properties
2018-07-13 16:22:12 +08:00
minggo 91719d5d94 convert data to RGBA888 when it is not (#1388) 2018-07-13 15:28:56 +08:00
wdzhangchukong 83d9a6fbff Provide loadImage api for runtime (#1374)
* Provide loadImage api for runtime

* Declare the jsb_global_load
2018-07-06 11:52:29 +08:00
W-MTZing 12d91c2f2d [feature] localStorage add api getKey and length (#1371) 2018-07-06 09:22:38 +08:00
Arnold c61d61682a Fix 7818 (#1370)
* fix: #7818

* fix: 7818

* add callback typecheck, should be function
2018-07-06 09:20:26 +08:00
leda 538f4b5df0 correct seLog declare error (#1356) 2018-07-02 20:54:24 +08:00
minggo 8e86f09df8 remove unneeded js script 2018-06-28 10:47:49 +08:00
minggo 5b8919ccdf merge develop branch 2018-06-27 17:27:04 +08:00
Jare Guo fe9ddce320 sync some files with develop (#1329) 2018-06-27 11:11:01 +08:00
leda 723f52a472 win32 link/default template compile and link pass, but not works when run (#1321)
* modify file changes on project config

* correct libcocos2d compile

* add win32 props back

* Revert "fix windows link template (#1138)"

This reverts commit 332d95e5b8.

* correct compile error

* many link errors need to be solved

* added part lack methods

* add empty impl for canvas rendering context 2d

* update main.cpp

* correct audio/network compile and link error

* sync win32 application logic with mac

* remove wrong change on application-win32

* correct win32 default-template compile and link error

* win32 simulator part compile error fixed

* editbox define changes
2018-06-22 10:19:31 +08:00
minggo 467b0346ce editbox support mac (#1322) 2018-06-21 09:25:56 +08:00
wuzhiming bc31a3993a use gzip to decompress js content 2018-06-19 15:44:12 +08:00
Vincent Yang 8f6e9adbe1 [feature] CCDownloader add header and abort support. (#1291)
*  [feature] android implement recieve http header param, handle it in android http request (#2)

* [feature] Recieve http header param, handle it in android http request

* [feature] implement abort and header api

* /2.0 -> /2

* remove task when abort

*  [feature] Implement ios and mac downloader abort api (#3)

* [feature] Implement ios and mac downloader abort api

* use DLLOG to show log

* judge NSURLSessionTask state with NSURLErrorCancelled

* [adjust] Modify downloader from auto bind to manually (#4)

* [adjust] Modify Downloader createDownloadFileTask api from auto bind to manually

* Modify ini file

* [bug] fix Cocos2dxDownloader.java syntax error

* [bug] CCDownloader-android creatCoTask don't deleteLocalRef header str
2018-06-07 22:19:03 +08:00
James Chen c7801b75f8 Minor fixes while running on macOS with V8 script engine. (#1305) 2018-06-07 16:08:06 +08:00
minggo 05bb9d46e4 [ci skip]default template works on mac (#1300) 2018-06-06 17:59:21 +08:00