summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-01-14 12:26:56 +0100
committerRémi Verschelde <rverschelde@gmail.com>2017-01-14 14:52:23 +0100
commit93ab45b6b5c4f8e0619e963156c983009d399a9d (patch)
tree80e55993f29ad7bf502ef7388eef78114b2dc4ab /platform
parent78e90ac60b81f17fdf8c319357f16962e92e6106 (diff)
Style: Fix whole-line commented code
They do not play well with clang-format which aligns the `//` part with the rest of the code block, thus producing badly indented commented code.
Diffstat (limited to 'platform')
-rw-r--r--platform/android/audio_driver_jandroid.cpp2
-rw-r--r--platform/android/audio_driver_opensl.cpp8
-rw-r--r--platform/android/dir_access_jandroid.cpp2
-rw-r--r--platform/android/export/export.cpp24
-rw-r--r--platform/android/file_access_jandroid.cpp2
-rw-r--r--platform/android/globals/global_defaults.cpp2
-rw-r--r--platform/android/godot_android.cpp48
-rw-r--r--platform/android/java/src/org/godotengine/godot/Godot.java30
-rw-r--r--platform/android/java/src/org/godotengine/godot/GodotDownloaderService.java2
-rw-r--r--platform/android/java/src/org/godotengine/godot/GodotView.java2
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/ConsumeTask.java16
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/GenericConsumeTask.java4
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/HandlePurchaseTask.java22
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/PaymentsCache.java4
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/PurchaseTask.java22
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/ReleaseAllConsumablesTask.java14
-rw-r--r--platform/android/java/src/org/godotengine/godot/payments/ValidateTask.java10
-rw-r--r--platform/android/java/src/org/godotengine/godot/utils/HttpRequester.java14
-rw-r--r--platform/android/java_class_wrapper.cpp2
-rw-r--r--platform/android/java_glue.cpp12
-rw-r--r--platform/android/os_android.cpp2
-rw-r--r--platform/bb10/os_bb10.cpp8
-rw-r--r--platform/bb10/os_bb10.h2
-rw-r--r--platform/haiku/haiku_direct_window.cpp10
-rw-r--r--platform/haiku/os_haiku.cpp8
-rw-r--r--platform/javascript/audio_driver_javascript.cpp12
-rw-r--r--platform/javascript/audio_server_javascript.cpp8
-rw-r--r--platform/javascript/javascript_main.cpp4
-rw-r--r--platform/javascript/os_javascript.cpp10
-rw-r--r--platform/osx/os_osx.h2
-rw-r--r--platform/osx/os_osx.mm103
-rw-r--r--platform/server/os_server.cpp8
-rw-r--r--platform/server/os_server.h2
-rw-r--r--platform/uwp/os_uwp.cpp8
-rw-r--r--platform/windows/context_gl_win.cpp2
-rw-r--r--platform/windows/os_windows.cpp28
-rw-r--r--platform/x11/context_gl_x11.cpp2
-rw-r--r--platform/x11/context_gl_x11.h2
-rw-r--r--platform/x11/key_mapping_x11.cpp4
-rw-r--r--platform/x11/os_x11.cpp14
40 files changed, 264 insertions, 217 deletions
diff --git a/platform/android/audio_driver_jandroid.cpp b/platform/android/audio_driver_jandroid.cpp
index 8c57eaaab6..d9e40a5913 100644
--- a/platform/android/audio_driver_jandroid.cpp
+++ b/platform/android/audio_driver_jandroid.cpp
@@ -71,7 +71,7 @@ Error AudioDriverAndroid::init(){
}
*/
-// Android_JNI_SetupThread();
+ //Android_JNI_SetupThread();
// __android_log_print(ANDROID_LOG_VERBOSE, "SDL", "SDL audio: opening device");
diff --git a/platform/android/audio_driver_opensl.cpp b/platform/android/audio_driver_opensl.cpp
index 5e3cfcbbab..7aec2b174e 100644
--- a/platform/android/audio_driver_opensl.cpp
+++ b/platform/android/audio_driver_opensl.cpp
@@ -108,7 +108,7 @@ void AudioDriverOpenSL::_buffer_callbacks(
AudioDriverOpenSL *ad = (AudioDriverOpenSL*)pContext;
-// ad->_buffer_callback(queueItf,eventFlags,pBuffer,bufferSize,dataUsed);
+ //ad->_buffer_callback(queueItf,eventFlags,pBuffer,bufferSize,dataUsed);
ad->_buffer_callback(queueItf);
}
@@ -271,8 +271,8 @@ void AudioDriverOpenSL::start(){
ERR_FAIL_COND( res !=SL_RESULT_SUCCESS );
SLDataLocator_AndroidSimpleBufferQueue loc_bufq = {SL_DATALOCATOR_ANDROIDSIMPLEBUFFERQUEUE, BUFFER_COUNT};
-// bufferQueue.locatorType = SL_DATALOCATOR_BUFFERQUEUE;
-// bufferQueue.numBuffers = BUFFER_COUNT; /* Four buffers in our buffer queue */
+ //bufferQueue.locatorType = SL_DATALOCATOR_BUFFERQUEUE;
+ //bufferQueue.numBuffers = BUFFER_COUNT; /* Four buffers in our buffer queue */
/* Setup the format of the content in the buffer queue */
pcm.formatType = SL_DATAFORMAT_PCM;
pcm.numChannels = 2;
@@ -295,7 +295,7 @@ void AudioDriverOpenSL::start(){
audioSink.pLocator = (void *)&locator_outputmix;
audioSink.pFormat = NULL;
/* Initialize the context for Buffer queue callbacks */
-// cntxt.pDataBase = (void*)&pcmData;
+ //cntxt.pDataBase = (void*)&pcmData;
//cntxt.pData = cntxt.pDataBase;
//cntxt.size = sizeof(pcmData);
/* Set arrays required[] and iidArray[] for SEEK interface
diff --git a/platform/android/dir_access_jandroid.cpp b/platform/android/dir_access_jandroid.cpp
index b6d4f757f9..2528b18248 100644
--- a/platform/android/dir_access_jandroid.cpp
+++ b/platform/android/dir_access_jandroid.cpp
@@ -257,7 +257,7 @@ void DirAccessJAndroid::setup( jobject p_io) {
__android_log_print(ANDROID_LOG_INFO,"godot","*******GOT METHOD _dir_is_dir ok!!");
}
-// (*env)->CallVoidMethod(env,obj,aMethodID, myvar);
+ //(*env)->CallVoidMethod(env,obj,aMethodID, myvar);
}
diff --git a/platform/android/export/export.cpp b/platform/android/export/export.cpp
index e836258e04..204bf684b7 100644
--- a/platform/android/export/export.cpp
+++ b/platform/android/export/export.cpp
@@ -729,17 +729,17 @@ void EditorExportPlatformAndroid::_fix_manifest(Vector<uint8_t>& p_manifest,bool
}
-// print_line("String "+itos(i)+": "+string_table[i]);
+ //print_line("String "+itos(i)+": "+string_table[i]);
}
for(uint32_t i=string_end;i<(ofs+size);i++) {
stable_extra.push_back(p_manifest[i]);
}
-// printf("stable extra: %i\n",int(stable_extra.size()));
+ //printf("stable extra: %i\n",int(stable_extra.size()));
string_table_ends=ofs+size;
-// print_line("STABLE SIZE: "+itos(size)+" ACTUAL: "+itos(string_table_ends));
+ //print_line("STABLE SIZE: "+itos(size)+" ACTUAL: "+itos(string_table_ends));
} break;
case CHUNK_XML_START_TAG: {
@@ -752,7 +752,7 @@ void EditorExportPlatformAndroid::_fix_manifest(Vector<uint8_t>& p_manifest,bool
String tname=string_table[name];
-// printf("NSPACE: %i\n",nspace);
+ //printf("NSPACE: %i\n",nspace);
//printf("NAME: %i (%s)\n",name,tname.utf8().get_data());
//printf("CHECK: %x\n",check);
uint32_t attrcount=decode_uint32(&p_manifest[iofs+20]);
@@ -1523,7 +1523,7 @@ void EditorExportPlatformAndroid::_device_poll_thread(void *ud) {
if (dpos==-1)
continue;
d=d.substr(0,dpos).strip_edges();
- // print_line("found devuce: "+d);
+ //print_line("found devuce: "+d);
ldevices.push_back(d);
}
@@ -1602,8 +1602,8 @@ void EditorExportPlatformAndroid::_device_poll_thread(void *ud) {
}
d.name=vendor+" "+device;
- // print_line("name: "+d.name);
- // print_line("description: "+d.description);
+ //print_line("name: "+d.name);
+ //print_line("description: "+d.description);
}
@@ -1864,10 +1864,12 @@ bool EditorExportPlatformAndroid::can_export(String *r_error) const {
if (apk_expansion) {
- //if (apk_expansion_salt=="") {
- // valid=false;
- // err+="Invalid SALT for apk expansion.\n";
- //}
+ /*
+ if (apk_expansion_salt=="") {
+ valid=false;
+ err+="Invalid SALT for apk expansion.\n";
+ }
+ */
if (apk_expansion_pkey=="") {
valid=false;
err+="Invalid public key for apk expansion.\n";
diff --git a/platform/android/file_access_jandroid.cpp b/platform/android/file_access_jandroid.cpp
index 4755f1d029..a4e9c191e9 100644
--- a/platform/android/file_access_jandroid.cpp
+++ b/platform/android/file_access_jandroid.cpp
@@ -236,7 +236,7 @@ void FileAccessJAndroid::setup( jobject p_io) {
__android_log_print(ANDROID_LOG_INFO,"godot","*******GOT METHOD _file_close ok!!");
}
-// (*env)->CallVoidMethod(env,obj,aMethodID, myvar);
+ //(*env)->CallVoidMethod(env,obj,aMethodID, myvar);
}
diff --git a/platform/android/globals/global_defaults.cpp b/platform/android/globals/global_defaults.cpp
index 52b59b2dc1..bbf9bd5b0b 100644
--- a/platform/android/globals/global_defaults.cpp
+++ b/platform/android/globals/global_defaults.cpp
@@ -35,7 +35,7 @@ void register_android_global_defaults() {
/* GLOBAL_DEF("rasterizer.Android/use_fragment_lighting",false);
GLOBAL_DEF("rasterizer.Android/fp16_framebuffer",false);
GLOBAL_DEF("display.Android/driver","GLES2");
-// GLOBAL_DEF("rasterizer.Android/trilinear_mipmap_filter",false);
+ //GLOBAL_DEF("rasterizer.Android/trilinear_mipmap_filter",false);
GlobalConfig::get_singleton()->set_custom_property_info("display.Android/driver",PropertyInfo(Variant::STRING,"display.Android/driver",PROPERTY_HINT_ENUM,"GLES2"));
*/
diff --git a/platform/android/godot_android.cpp b/platform/android/godot_android.cpp
index c4d1a85c5f..3c7f7f5854 100644
--- a/platform/android/godot_android.cpp
+++ b/platform/android/godot_android.cpp
@@ -535,29 +535,33 @@ static int32_t engine_handle_input(struct android_app* app, AInputEvent* event)
case AMOTION_EVENT_ACTION_DOWN: {
engine->os->process_touch(0,0,touchvec);
- //System.out.printf("action down at: %f,%f\n", event.getX(),event.getY());
+ //System.out.printf("action down at: %f,%f\n", event.getX(),event.getY());
} break;
case AMOTION_EVENT_ACTION_MOVE: {
engine->os->process_touch(1,0,touchvec);
- //for(int i=0;i<event.getPointerCount();i++) {
- // System.out.printf("%d - moved to: %f,%f\n",i, event.getX(i),event.getY(i));
- //}
+ /*
+ for(int i=0;i<event.getPointerCount();i++) {
+ System.out.printf("%d - moved to: %f,%f\n",i, event.getX(i),event.getY(i));
+ }
+ */
} break;
case AMOTION_EVENT_ACTION_POINTER_UP: {
engine->os->process_touch(4,pidx,touchvec);
- //System.out.printf("%d - s.up at: %f,%f\n",pointer_idx, event.getX(pointer_idx),event.getY(pointer_idx));
+ //System.out.printf("%d - s.up at: %f,%f\n",pointer_idx, event.getX(pointer_idx),event.getY(pointer_idx));
} break;
case AMOTION_EVENT_ACTION_POINTER_DOWN: {
engine->os->process_touch(3,pidx,touchvec);
- //System.out.printf("%d - s.down at: %f,%f\n",pointer_idx, event.getX(pointer_idx),event.getY(pointer_idx));
+ //System.out.printf("%d - s.down at: %f,%f\n",pointer_idx, event.getX(pointer_idx),event.getY(pointer_idx));
} break;
case AMOTION_EVENT_ACTION_CANCEL:
case AMOTION_EVENT_ACTION_UP: {
engine->os->process_touch(2,0,touchvec);
- //for(int i=0;i<event.getPointerCount();i++) {
- // System.out.printf("%d - up! %f,%f\n",i, event.getX(i),event.getY(i));
- //}
+ /*
+ for(int i=0;i<event.getPointerCount();i++) {
+ System.out.printf("%d - up! %f,%f\n",i, event.getX(i),event.getY(i));
+ }
+ */
} break;
}
@@ -638,8 +642,8 @@ static void engine_handle_cmd(struct android_app* app, int32_t cmd) {
} break;
case APP_CMD_INIT_WINDOW:
- //The window is being shown, get it ready.
- // LOGI("INIT WINDOW");
+ //The window is being shown, get it ready.
+ //LOGI("INIT WINDOW");
if (engine->app->window != NULL) {
if (engine->os==NULL) {
@@ -647,7 +651,7 @@ static void engine_handle_cmd(struct android_app* app, int32_t cmd) {
//do initialization here, when there's OpenGL! hackish but the only way
engine->os = new OS_Android(_gfx_init,engine);
- // char *args[]={"-test","gui",NULL};
+ //char *args[]={"-test","gui",NULL};
__android_log_print(ANDROID_LOG_INFO,"godot","pre asdasd setup...");
#if 0
Error err = Main::setup("apk",2,args);
@@ -722,15 +726,15 @@ static void engine_handle_cmd(struct android_app* app, int32_t cmd) {
engine->animating=1;
engine_draw_frame(engine);
}
- break;
+ break;
case APP_CMD_TERM_WINDOW:
- // The window is being hidden or closed, clean it up.
- // LOGI("TERM WINDOW");
- engine_term_display(engine);
- break;
+ // The window is being hidden or closed, clean it up.
+ //LOGI("TERM WINDOW");
+ engine_term_display(engine);
+ break;
case APP_CMD_GAINED_FOCUS:
- // When our app gains focus, we start monitoring the accelerometer.
- if (engine->accelerometerSensor != NULL) {
+ // When our app gains focus, we start monitoring the accelerometer.
+ if (engine->accelerometerSensor != NULL) {
ASensorEventQueue_enableSensor(engine->sensorEventQueue,
engine->accelerometerSensor);
// We'd like to get 60 events per second (in us).
@@ -833,7 +837,7 @@ void android_main(struct android_app* state) {
// Process this event.
if (source != NULL) {
- // LOGI("process\n");
+ // LOGI("process\n");
source->process(state, source);
} else {
nullmax--;
@@ -883,12 +887,12 @@ void android_main(struct android_app* state) {
return;
}
-// LOGI("end\n");
+ // LOGI("end\n");
}
-// LOGI("engine animating? %i\n",engine.animating);
+ // LOGI("engine animating? %i\n",engine.animating);
if (engine.animating) {
//do os render
diff --git a/platform/android/java/src/org/godotengine/godot/Godot.java b/platform/android/java/src/org/godotengine/godot/Godot.java
index 94d29a3350..610f707b47 100644
--- a/platform/android/java/src/org/godotengine/godot/Godot.java
+++ b/platform/android/java/src/org/godotengine/godot/Godot.java
@@ -257,8 +257,8 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
public void onVideoInit(boolean use_gl2) {
-// mView = new GodotView(getApplication(),io,use_gl2);
-// setContentView(mView);
+ //mView = new GodotView(getApplication(),io,use_gl2);
+ //setContentView(mView);
layout = new FrameLayout(this);
layout.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT,LayoutParams.FILL_PARENT));
@@ -582,7 +582,7 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
initializeGodot();
- // instanceSingleton( new GodotFacebook(this) );
+ //instanceSingleton( new GodotFacebook(this) );
}
@@ -804,9 +804,11 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
} break;
case MotionEvent.ACTION_MOVE: {
GodotLib.touch(1,0,evcount,arr);
- //for(int i=0;i<event.getPointerCount();i++) {
- // System.out.printf("%d - moved to: %f,%f\n",i, event.getX(i),event.getY(i));
- //}
+ /*
+ for(int i=0;i<event.getPointerCount();i++) {
+ System.out.printf("%d - moved to: %f,%f\n",i, event.getX(i),event.getY(i));
+ }
+ */
} break;
case MotionEvent.ACTION_POINTER_UP: {
final int indexPointUp = event.getActionIndex();
@@ -822,9 +824,11 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
case MotionEvent.ACTION_CANCEL:
case MotionEvent.ACTION_UP: {
GodotLib.touch(2,0,evcount,arr);
- //for(int i=0;i<event.getPointerCount();i++) {
- // System.out.printf("%d - up! %f,%f\n",i, event.getX(i),event.getY(i));
- //}
+ /*
+ for(int i=0;i<event.getPointerCount();i++) {
+ System.out.printf("%d - up! %f,%f\n",i, event.getX(i),event.getY(i));
+ }
+ */
} break;
}
@@ -866,9 +870,11 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
return mPaymentsManager;
}
-// public void setPaymentsManager(PaymentsManager mPaymentsManager) {
-// this.mPaymentsManager = mPaymentsManager;
-// };
+ /*
+ public void setPaymentsManager(PaymentsManager mPaymentsManager) {
+ this.mPaymentsManager = mPaymentsManager;
+ }
+ */
// Audio
diff --git a/platform/android/java/src/org/godotengine/godot/GodotDownloaderService.java b/platform/android/java/src/org/godotengine/godot/GodotDownloaderService.java
index 878528f7c7..fba082e80d 100644
--- a/platform/android/java/src/org/godotengine/godot/GodotDownloaderService.java
+++ b/platform/android/java/src/org/godotengine/godot/GodotDownloaderService.java
@@ -57,7 +57,7 @@ public class GodotDownloaderService extends DownloaderService {
Log.d("GODOT", "getting public key:" + prefs.getString("store_public_key", null));
return prefs.getString("store_public_key", null);
-// return BASE64_PUBLIC_KEY;
+ //return BASE64_PUBLIC_KEY;
}
/**
diff --git a/platform/android/java/src/org/godotengine/godot/GodotView.java b/platform/android/java/src/org/godotengine/godot/GodotView.java
index db67144bcc..4cfe295835 100644
--- a/platform/android/java/src/org/godotengine/godot/GodotView.java
+++ b/platform/android/java/src/org/godotengine/godot/GodotView.java
@@ -265,7 +265,7 @@ public class GodotView extends GLSurfaceView implements InputDeviceListener {
if (keyCode == KeyEvent.KEYCODE_BACK) {
GodotLib.quit();
// press 'back' button should not terminate program
- // normal handle 'back' event in game logic
+ //normal handle 'back' event in game logic
return true;
}
diff --git a/platform/android/java/src/org/godotengine/godot/payments/ConsumeTask.java b/platform/android/java/src/org/godotengine/godot/payments/ConsumeTask.java
index 13a24994f8..67293df2a8 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/ConsumeTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/ConsumeTask.java
@@ -47,19 +47,19 @@ abstract public class ConsumeTask {
public void consume(final String sku){
-// Log.d("XXX", "Consuming product " + sku);
+ //Log.d("XXX", "Consuming product " + sku);
PaymentsCache pc = new PaymentsCache(context);
Boolean isBlocked = pc.getConsumableFlag("block", sku);
String _token = pc.getConsumableValue("token", sku);
-// Log.d("XXX", "token " + _token);
+ //Log.d("XXX", "token " + _token);
if(!isBlocked && _token == null){
-// _token = "inapp:"+context.getPackageName()+":android.test.purchased";
-// Log.d("XXX", "Consuming product " + sku + " with token " + _token);
+ //_token = "inapp:"+context.getPackageName()+":android.test.purchased";
+ //Log.d("XXX", "Consuming product " + sku + " with token " + _token);
}else if(!isBlocked){
-// Log.d("XXX", "It is not blocked ¿?");
+ //Log.d("XXX", "It is not blocked ¿?");
return;
}else if(_token == null){
-// Log.d("XXX", "No token available");
+ //Log.d("XXX", "No token available");
this.error("No token for sku:" + sku);
return;
}
@@ -69,9 +69,9 @@ abstract public class ConsumeTask {
@Override
protected String doInBackground(String... params) {
try {
-// Log.d("XXX", "Requesting to release item.");
+ //Log.d("XXX", "Requesting to release item.");
int response = mService.consumePurchase(3, context.getPackageName(), token);
-// Log.d("XXX", "release response code: " + response);
+ //Log.d("XXX", "release response code: " + response);
if(response == 0 || response == 8){
return null;
}
diff --git a/platform/android/java/src/org/godotengine/godot/payments/GenericConsumeTask.java b/platform/android/java/src/org/godotengine/godot/payments/GenericConsumeTask.java
index 20feaef581..dfa363ed75 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/GenericConsumeTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/GenericConsumeTask.java
@@ -60,9 +60,9 @@ abstract public class GenericConsumeTask extends AsyncTask<String, String, Strin
@Override
protected String doInBackground(String... params) {
try {
-// Log.d("godot", "Requesting to consume an item with token ." + token);
+ //Log.d("godot", "Requesting to consume an item with token ." + token);
int response = mService.consumePurchase(3, context.getPackageName(), token);
-// Log.d("godot", "consumePurchase response: " + response);
+ //Log.d("godot", "consumePurchase response: " + response);
if(response == 0 || response == 8){
return null;
}
diff --git a/platform/android/java/src/org/godotengine/godot/payments/HandlePurchaseTask.java b/platform/android/java/src/org/godotengine/godot/payments/HandlePurchaseTask.java
index 1aa210265d..3850453a77 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/HandlePurchaseTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/HandlePurchaseTask.java
@@ -56,29 +56,29 @@ abstract public class HandlePurchaseTask {
public void handlePurchaseRequest(int resultCode, Intent data){
-// Log.d("XXX", "Handling purchase response");
-// int responseCode = data.getIntExtra("RESPONSE_CODE", 0);
+ //Log.d("XXX", "Handling purchase response");
+ //int responseCode = data.getIntExtra("RESPONSE_CODE", 0);
PaymentsCache pc = new PaymentsCache(context);
String purchaseData = data.getStringExtra("INAPP_PURCHASE_DATA");
-// Log.d("XXX", "Purchase data:" + purchaseData);
+ //Log.d("XXX", "Purchase data:" + purchaseData);
String dataSignature = data.getStringExtra("INAPP_DATA_SIGNATURE");
//Log.d("XXX", "Purchase signature:" + dataSignature);
if (resultCode == Activity.RESULT_OK) {
try {
-// Log.d("SARLANGA", purchaseData);
+ //Log.d("SARLANGA", purchaseData);
JSONObject jo = new JSONObject(purchaseData);
-// String sku = jo.getString("productId");
-// alert("You have bought the " + sku + ". Excellent choice, aventurer!");
-// String orderId = jo.getString("orderId");
-// String packageName = jo.getString("packageName");
+ //String sku = jo.getString("productId");
+ //alert("You have bought the " + sku + ". Excellent choice, aventurer!");
+ //String orderId = jo.getString("orderId");
+ //String packageName = jo.getString("packageName");
String productId = jo.getString("productId");
-// Long purchaseTime = jo.getLong("purchaseTime");
-// Integer state = jo.getInt("purchaseState");
+ //Long purchaseTime = jo.getLong("purchaseTime");
+ //Integer state = jo.getInt("purchaseState");
String developerPayload = jo.getString("developerPayload");
String purchaseToken = jo.getString("purchaseToken");
@@ -86,7 +86,7 @@ abstract public class HandlePurchaseTask {
error("Untrusted callback");
return;
}
-// Log.d("XXX", "Este es el product ID:" + productId);
+ //Log.d("XXX", "Este es el product ID:" + productId);
pc.setConsumableValue("ticket_signautre", productId, dataSignature);
pc.setConsumableValue("ticket", productId, purchaseData);
pc.setConsumableFlag("block", productId, true);
diff --git a/platform/android/java/src/org/godotengine/godot/payments/PaymentsCache.java b/platform/android/java/src/org/godotengine/godot/payments/PaymentsCache.java
index 88fd1a0fe4..4678dae1b3 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/PaymentsCache.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/PaymentsCache.java
@@ -59,14 +59,14 @@ public class PaymentsCache {
SharedPreferences sharedPref = context.getSharedPreferences("consumables_" + set, Context.MODE_PRIVATE);
SharedPreferences.Editor editor = sharedPref.edit();
editor.putString(sku, value);
-// Log.d("XXX", "Setting asset: consumables_" + set + ":" + sku);
+ //Log.d("XXX", "Setting asset: consumables_" + set + ":" + sku);
editor.commit();
}
public String getConsumableValue(String set, String sku){
SharedPreferences sharedPref = context.getSharedPreferences(
"consumables_" + set, Context.MODE_PRIVATE);
-// Log.d("XXX", "Getting asset: consumables_" + set + ":" + sku);
+ //Log.d("XXX", "Getting asset: consumables_" + set + ":" + sku);
return sharedPref.getString(sku, null);
}
diff --git a/platform/android/java/src/org/godotengine/godot/payments/PurchaseTask.java b/platform/android/java/src/org/godotengine/godot/payments/PurchaseTask.java
index d154ef0c78..5ad96b35ee 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/PurchaseTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/PurchaseTask.java
@@ -63,18 +63,20 @@ abstract public class PurchaseTask {
Log.d("XXX", "Starting purchase for: " + sku);
PaymentsCache pc = new PaymentsCache(context);
Boolean isBlocked = pc.getConsumableFlag("block", sku);
-// if(isBlocked){
-// Log.d("XXX", "Is awaiting payment confirmation");
-// error("Awaiting payment confirmation");
-// return;
-// }
+ /*
+ if(isBlocked){
+ Log.d("XXX", "Is awaiting payment confirmation");
+ error("Awaiting payment confirmation");
+ return;
+ }
+ */
final String hash = transactionId;
Bundle buyIntentBundle;
try {
buyIntentBundle = mService.getBuyIntent(3, context.getApplicationContext().getPackageName(), sku, "inapp", hash );
} catch (RemoteException e) {
-// Log.d("XXX", "Error: " + e.getMessage());
+ //Log.d("XXX", "Error: " + e.getMessage());
error(e.getMessage());
return;
}
@@ -87,7 +89,7 @@ abstract public class PurchaseTask {
}else if( rc instanceof Long){
responseCode = (int)((Long)rc).longValue();
}
-// Log.d("XXX", "Buy intent response code: " + responseCode);
+ //Log.d("XXX", "Buy intent response code: " + responseCode);
if(responseCode == 1 || responseCode == 3 || responseCode == 4){
canceled();
return;
@@ -102,12 +104,12 @@ abstract public class PurchaseTask {
pc.setConsumableValue("validation_hash", sku, hash);
try {
if(context == null){
-// Log.d("XXX", "No context!");
+ //Log.d("XXX", "No context!");
}
if(pendingIntent == null){
-// Log.d("XXX", "No pending intent");
+ //Log.d("XXX", "No pending intent");
}
-// Log.d("XXX", "Starting activity for purchase!");
+ //Log.d("XXX", "Starting activity for purchase!");
context.startIntentSenderForResult(
pendingIntent.getIntentSender(),
PaymentsManager.REQUEST_CODE_FOR_PURCHASE,
diff --git a/platform/android/java/src/org/godotengine/godot/payments/ReleaseAllConsumablesTask.java b/platform/android/java/src/org/godotengine/godot/payments/ReleaseAllConsumablesTask.java
index c74269890d..60a43a9070 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/ReleaseAllConsumablesTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/ReleaseAllConsumablesTask.java
@@ -56,13 +56,13 @@ abstract public class ReleaseAllConsumablesTask {
public void consumeItAll(){
try{
-// Log.d("godot", "consumeItall for " + context.getPackageName());
+ //Log.d("godot", "consumeItall for " + context.getPackageName());
Bundle bundle = mService.getPurchases(3, context.getPackageName(), "inapp",null);
for (String key : bundle.keySet()) {
- Object value = bundle.get(key);
-// Log.d("godot", String.format("%s %s (%s)", key,
-// value.toString(), value.getClass().getName()));
+ Object value = bundle.get(key);
+ //Log.d("godot", String.format("%s %s (%s)", key,
+ //value.toString(), value.getClass().getName()));
}
@@ -73,13 +73,13 @@ abstract public class ReleaseAllConsumablesTask {
if (myPurchases == null || myPurchases.size() == 0){
-// Log.d("godot", "No purchases!");
+ //Log.d("godot", "No purchases!");
notRequired();
return;
}
-// Log.d("godot", "# products to be consumed:" + myPurchases.size());
+ //Log.d("godot", "# products to be consumed:" + myPurchases.size());
for (int i=0;i<myPurchases.size();i++)
{
@@ -89,7 +89,7 @@ abstract public class ReleaseAllConsumablesTask {
String sku = inappPurchaseData.getString("productId");
String token = inappPurchaseData.getString("purchaseToken");
String signature = mySignatures.get(i);
-// Log.d("godot", "A punto de consumir un item con token:" + token + "\n" + receipt);
+ //Log.d("godot", "A punto de consumir un item con token:" + token + "\n" + receipt);
new GenericConsumeTask(context, mService, sku, receipt,signature, token) {
@Override
diff --git a/platform/android/java/src/org/godotengine/godot/payments/ValidateTask.java b/platform/android/java/src/org/godotengine/godot/payments/ValidateTask.java
index dafab13ad7..f09bcbf9a4 100644
--- a/platform/android/java/src/org/godotengine/godot/payments/ValidateTask.java
+++ b/platform/android/java/src/org/godotengine/godot/payments/ValidateTask.java
@@ -79,14 +79,14 @@ abstract public class ValidateTask {
param.put("ticket", pc.getConsumableValue("ticket", sku));
param.put("purchaseToken", pc.getConsumableValue("token", sku));
param.put("sku", sku);
-// Log.d("XXX", "Haciendo request a " + url);
-// Log.d("XXX", "ticket: " + pc.getConsumableValue("ticket", sku));
-// Log.d("XXX", "purchaseToken: " + pc.getConsumableValue("token", sku));
-// Log.d("XXX", "sku: " + sku);
+ //Log.d("XXX", "Haciendo request a " + url);
+ //Log.d("XXX", "ticket: " + pc.getConsumableValue("ticket", sku));
+ //Log.d("XXX", "purchaseToken: " + pc.getConsumableValue("token", sku));
+ //Log.d("XXX", "sku: " + sku);
param.put("package", context.getApplicationContext().getPackageName());
HttpRequester requester = new HttpRequester();
String jsonResponse = requester.post(param);
-// Log.d("XXX", "Validation response:\n"+jsonResponse);
+ //Log.d("XXX", "Validation response:\n"+jsonResponse);
return jsonResponse;
}
diff --git a/platform/android/java/src/org/godotengine/godot/utils/HttpRequester.java b/platform/android/java/src/org/godotengine/godot/utils/HttpRequester.java
index 9dd08a9563..faefbbd2c6 100644
--- a/platform/android/java/src/org/godotengine/godot/utils/HttpRequester.java
+++ b/platform/android/java/src/org/godotengine/godot/utils/HttpRequester.java
@@ -78,12 +78,12 @@ public class HttpRequester {
private long cttl=0;
public HttpRequester(){
-// Log.d("XXX", "Creando http request sin contexto");
+ //Log.d("XXX", "Creando http request sin contexto");
}
public HttpRequester(Context context){
this.context=context;
-// Log.d("XXX", "Creando http request con contexto");
+ //Log.d("XXX", "Creando http request con contexto");
}
public String post(RequestParams params){
@@ -99,7 +99,7 @@ public class HttpRequester {
public String get(RequestParams params){
String response = getResponseFromCache(params.getUrl());
if(response == null){
-// Log.d("XXX", "Cache miss!");
+ //Log.d("XXX", "Cache miss!");
HttpGet httpget = new HttpGet(params.getUrl());
long timeInit = new Date().getTime();
response = request(httpget);
@@ -117,7 +117,7 @@ public class HttpRequester {
}
private String request(HttpUriRequest request){
-// Log.d("XXX", "Haciendo request a: " + request.getURI() );
+ //Log.d("XXX", "Haciendo request a: " + request.getURI() );
Log.d("PPP", "Haciendo request a: " + request.getURI() );
long init = new Date().getTime();
HttpClient httpclient = getNewHttpClient();
@@ -128,10 +128,10 @@ public class HttpRequester {
try {
HttpResponse response = httpclient.execute(request);
Log.d("PPP", "Fin de request (" + (new Date().getTime() - init) + ") a: " + request.getURI() );
-// Log.d("XXX1", "Status:" + response.getStatusLine().toString());
+ //Log.d("XXX1", "Status:" + response.getStatusLine().toString());
if(response.getStatusLine().getStatusCode() == 200){
String strResponse = EntityUtils.toString(response.getEntity());
-// Log.d("XXX2", strResponse);
+ //Log.d("XXX2", strResponse);
return strResponse;
}else{
Log.d("XXX3", "Response status code:" + response.getStatusLine().getStatusCode() + "\n" + EntityUtils.toString(response.getEntity()));
@@ -192,7 +192,7 @@ public class HttpRequester {
public void saveResponseIntoCache(String request, String response){
if(context == null){
-// Log.d("XXX", "No context, cache failed!");
+ //Log.d("XXX", "No context, cache failed!");
return;
}
SharedPreferences sharedPref = context.getSharedPreferences("http_get_cache", Context.MODE_PRIVATE);
diff --git a/platform/android/java_class_wrapper.cpp b/platform/android/java_class_wrapper.cpp
index 296ac0a831..9acda005f1 100644
--- a/platform/android/java_class_wrapper.cpp
+++ b/platform/android/java_class_wrapper.cpp
@@ -1240,7 +1240,7 @@ Ref<JavaClass> JavaClassWrapper::wrap(const String& p_class) {
//args[i] = _jobject_to_variant(env, obj);
-// print_line("\targ"+itos(i)+": "+Variant::get_type_name(args[i].get_type()));
+ //print_line("\targ"+itos(i)+": "+Variant::get_type_name(args[i].get_type()));
};
diff --git a/platform/android/java_glue.cpp b/platform/android/java_glue.cpp
index a691e60575..dfbb437344 100644
--- a/platform/android/java_glue.cpp
+++ b/platform/android/java_glue.cpp
@@ -802,7 +802,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_initialize(JNIEnv * e
env->GetJavaVM(&jvm);
_godot_instance=env->NewGlobalRef(activity);
-// _godot_instance=activity;
+ //_godot_instance=activity;
__android_log_print(ANDROID_LOG_INFO,"godot","***************** HELLO FROM JNI!!!!!!!!");
@@ -879,7 +879,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_initialize(JNIEnv * e
if (!rawString) {
__android_log_print(ANDROID_LOG_INFO,"godot","cmdline arg %i is null\n",i);
} else {
- // __android_log_print(ANDROID_LOG_INFO,"godot","cmdline arg %i is: %s\n",i,rawString);
+ //__android_log_print(ANDROID_LOG_INFO,"godot","cmdline arg %i is: %s\n",i,rawString);
if (strcmp(rawString,"-main_pack")==0)
use_apk_expansion=true;
@@ -1151,8 +1151,10 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_touch(JNIEnv * env, j
pointer_events.push_back(jpe);
input_mutex->unlock();
- //if (os_android)
-// os_android->process_touch(ev,pointer,points);
+ /*
+ if (os_android)
+ os_android->process_touch(ev,pointer,points);
+ */
}
@@ -1753,7 +1755,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_calldeferred(JNIEnv *
args[i] = _jobject_to_variant(env, obj);
env->DeleteLocalRef(obj);
-// print_line("\targ"+itos(i)+": "+Variant::get_type_name(args[i].get_type()));
+ //print_line("\targ"+itos(i)+": "+Variant::get_type_name(args[i].get_type()));
};
diff --git a/platform/android/os_android.cpp b/platform/android/os_android.cpp
index 3fcb6949ac..562666b679 100644
--- a/platform/android/os_android.cpp
+++ b/platform/android/os_android.cpp
@@ -399,7 +399,7 @@ void OS_Android::process_event(InputEvent p_event) {
void OS_Android::process_touch(int p_what,int p_pointer, const Vector<TouchPos>& p_points) {
-// print_line("ev: "+itos(p_what)+" pnt: "+itos(p_pointer)+" pointc: "+itos(p_points.size()));
+ //print_line("ev: "+itos(p_what)+" pnt: "+itos(p_pointer)+" pointc: "+itos(p_points.size()));
switch(p_what) {
case 0: { //gesture begin
diff --git a/platform/bb10/os_bb10.cpp b/platform/bb10/os_bb10.cpp
index 3913c31320..ea2e326b05 100644
--- a/platform/bb10/os_bb10.cpp
+++ b/platform/bb10/os_bb10.cpp
@@ -190,9 +190,11 @@ void OSBB10::finalize() {
spatial_sound_2d_server->finish();
memdelete(spatial_sound_2d_server);
- //if (debugger_connection_console) {
-// memdelete(debugger_connection_console);
-//}
+ /*
+ if (debugger_connection_console) {
+ memdelete(debugger_connection_console);
+ }
+ */
memdelete(sample_manager);
diff --git a/platform/bb10/os_bb10.h b/platform/bb10/os_bb10.h
index 8011550987..5c484cd120 100644
--- a/platform/bb10/os_bb10.h
+++ b/platform/bb10/os_bb10.h
@@ -58,7 +58,7 @@ class OSBB10 : public OS_Unix {
Rasterizer *rasterizer;
VisualServer *visual_server;
-// AudioDriverPSP audio_driver_psp;
+ //AudioDriverPSP audio_driver_psp;
AudioServerSW *audio_server;
SampleManagerMallocSW *sample_manager;
SpatialSoundServerSW *spatial_sound_server;
diff --git a/platform/haiku/haiku_direct_window.cpp b/platform/haiku/haiku_direct_window.cpp
index 2a8310b858..e7ff65e3ba 100644
--- a/platform/haiku/haiku_direct_window.cpp
+++ b/platform/haiku/haiku_direct_window.cpp
@@ -145,10 +145,12 @@ void HaikuDirectWindow::HandleMouseButton(BMessage* message) {
last_buttons_state = buttons;
// TODO: implement the mouse_mode checks
- //if (mouse_mode == MOUSE_MODE_CAPTURED) {
- // event.xbutton.x=last_mouse_pos.x;
- // event.xbutton.y=last_mouse_pos.y;
- //}
+ /*
+ if (mouse_mode == MOUSE_MODE_CAPTURED) {
+ event.xbutton.x=last_mouse_pos.x;
+ event.xbutton.y=last_mouse_pos.y;
+ }
+ */
InputEvent mouse_event;
mouse_event.ID = ++event_id;
diff --git a/platform/haiku/os_haiku.cpp b/platform/haiku/os_haiku.cpp
index 10e1b055be..176e1b0fbc 100644
--- a/platform/haiku/os_haiku.cpp
+++ b/platform/haiku/os_haiku.cpp
@@ -119,9 +119,11 @@ void OS_Haiku::initialize(const VideoMode& p_desired, int p_video_driver, int p_
ERR_FAIL_COND(!visual_server);
// TODO: enable multithreaded VS
- //if (get_render_thread_mode() != RENDER_THREAD_UNSAFE) {
- // visual_server = memnew(VisualServerWrapMT(visual_server, get_render_thread_mode() == RENDER_SEPARATE_THREAD));
- //}
+ /*
+ if (get_render_thread_mode() != RENDER_THREAD_UNSAFE) {
+ visual_server = memnew(VisualServerWrapMT(visual_server, get_render_thread_mode() == RENDER_SEPARATE_THREAD));
+ }
+ */
input = memnew(InputDefault);
window->SetInput(input);
diff --git a/platform/javascript/audio_driver_javascript.cpp b/platform/javascript/audio_driver_javascript.cpp
index 579cbaed3c..af9f28169b 100644
--- a/platform/javascript/audio_driver_javascript.cpp
+++ b/platform/javascript/audio_driver_javascript.cpp
@@ -68,14 +68,18 @@ AudioDriverSW::OutputFormat AudioDriverJavaScript::get_output_format() const{
}
void AudioDriverJavaScript::lock(){
- //if (active && mutex)
- // mutex->lock();
+ /*
+ if (active && mutex)
+ mutex->lock();
+ */
}
void AudioDriverJavaScript::unlock() {
- //if (active && mutex)
- // mutex->unlock();
+ /*
+ if (active && mutex)
+ mutex->unlock();
+ */
}
void AudioDriverJavaScript::finish(){
diff --git a/platform/javascript/audio_server_javascript.cpp b/platform/javascript/audio_server_javascript.cpp
index d1fba030a5..5489f179eb 100644
--- a/platform/javascript/audio_server_javascript.cpp
+++ b/platform/javascript/audio_server_javascript.cpp
@@ -617,9 +617,11 @@ void AudioServerJavascript::mix_to_js(int p_frames) {
void AudioServerJavascript::init(){
- //EM_ASM(
-// console.log('server is '+audio_server);
-// );
+ /*
+ EM_ASM(
+ console.log('server is '+audio_server);
+ );
+ */
//int latency = GLOBAL_DEF("javascript/audio_latency",16384);
diff --git a/platform/javascript/javascript_main.cpp b/platform/javascript/javascript_main.cpp
index 4c47594810..6ec7f1ec3d 100644
--- a/platform/javascript/javascript_main.cpp
+++ b/platform/javascript/javascript_main.cpp
@@ -159,8 +159,8 @@ int main(int argc, char *argv[]) {
char *args[]={"-test","gui","-v",NULL};
Error err = Main::setup("apk",3,args);
#else
-// char *args[]={"-v",NULL};//
-// Error err = Main::setup("",1,args);
+ //char *args[]={"-v",NULL};//
+ //Error err = Main::setup("",1,args);
Error err = Main::setup("",0,NULL);
#endif
diff --git a/platform/javascript/os_javascript.cpp b/platform/javascript/os_javascript.cpp
index a6be77340f..18bf8f6a86 100644
--- a/platform/javascript/os_javascript.cpp
+++ b/platform/javascript/os_javascript.cpp
@@ -243,7 +243,7 @@ void OS_JavaScript::initialize(const VideoMode& p_desired,int p_video_driver,int
rasterizer_gles22->set_extensions(gl_extensions);
rasterizer = rasterizer_gles22;
} else {
-// rasterizer = memnew( RasterizerGLES1(true, false) );
+ //rasterizer = memnew( RasterizerGLES1(true, false) );
}
print_line("Init VS");
@@ -561,7 +561,7 @@ void OS_JavaScript::push_input(const InputEvent& p_ev) {
void OS_JavaScript::process_touch(int p_what,int p_pointer, const Vector<TouchPos>& p_points) {
-// print_line("ev: "+itos(p_what)+" pnt: "+itos(p_pointer)+" pointc: "+itos(p_points.size()));
+ //print_line("ev: "+itos(p_what)+" pnt: "+itos(p_pointer)+" pointc: "+itos(p_points.size()));
switch(p_what) {
case 0: { //gesture begin
@@ -804,8 +804,10 @@ String OS_JavaScript::get_resource_dir() const {
String OS_JavaScript::get_data_dir() const {
- //if (get_data_dir_func)
- // return get_data_dir_func();
+ /*
+ if (get_data_dir_func)
+ return get_data_dir_func();
+ */
return "/userfs";
//return GlobalConfig::get_singleton()->get_singleton_object("GodotOS")->call("get_data_dir");
};
diff --git a/platform/osx/os_osx.h b/platform/osx/os_osx.h
index fc64c2b867..f6559f1f7a 100644
--- a/platform/osx/os_osx.h
+++ b/platform/osx/os_osx.h
@@ -59,7 +59,7 @@ class OS_OSX : public OS_Unix {
public:
bool force_quit;
// rasterizer seems to no longer be given to visual server, its using GLES3 directly?
-// Rasterizer *rasterizer;
+ //Rasterizer *rasterizer;
VisualServer *visual_server;
List<String> args;
diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm
index a66f6abba5..5750e19c87 100644
--- a/platform/osx/os_osx.mm
+++ b/platform/osx/os_osx.mm
@@ -148,36 +148,36 @@ static int button_mask=0;
- (void)applicationDidHide:(NSNotification *)notification
{
- /* _Godotwindow* window;
-
- for (window = _Godot.windowListHead; window; window = window->next)
- _GodotInputWindowVisibility(window, GL_FALSE);
+ /*
+ _Godotwindow* window;
+ for (window = _Godot.windowListHead; window; window = window->next)
+ _GodotInputWindowVisibility(window, GL_FALSE);
*/
}
- (void)applicationDidUnhide:(NSNotification *)notification
{
/*
- _Godotwindow* window;
+ _Godotwindow* window;
- for (window = _Godot.windowListHead; window; window = window->next)
- {
+ for (window = _Godot.windowListHead; window; window = window->next)
+ {
if ([window_object isVisible])
_GodotInputWindowVisibility(window, GL_TRUE);
- }
- */
+ }
+ */
}
- (void)applicationDidChangeScreenParameters:(NSNotification *) notification
{
- //_GodotInputMonitorChange();
+ //_GodotInputMonitorChange();
}
@end
@interface GodotWindowDelegate : NSObject
{
- // _Godotwindow* window;
+ //_Godotwindow* window;
}
@end
@@ -187,7 +187,7 @@ static int button_mask=0;
- (BOOL)windowShouldClose:(id)sender
{
- //_GodotInputWindowCloseRequest(window);
+ //_GodotInputWindowCloseRequest(window);
if (OS_OSX::singleton->get_main_loop())
OS_OSX::singleton->get_main_loop()->notification(MainLoop::NOTIFICATION_WM_QUIT_REQUEST);
return NO;
@@ -207,38 +207,42 @@ static int button_mask=0;
OS_OSX::singleton->window_size.height=fbRect.size.height*OS_OSX::singleton->display_scale;
- // _GodotInputFramebufferSize(window, fbRect.size.width, fbRect.size.height);
- // _GodotInputWindowSize(window, contentRect.size.width, contentRect.size.height);
- //_GodotInputWindowDamage(window);
+ /*
+ _GodotInputFramebufferSize(window, fbRect.size.width, fbRect.size.height);
+ _GodotInputWindowSize(window, contentRect.size.width, contentRect.size.height);
+ _GodotInputWindowDamage(window);
- //if (window->cursorMode == Godot_CURSOR_DISABLED)
- // centerCursor(window);
+ if (window->cursorMode == Godot_CURSOR_DISABLED)
+ centerCursor(window);
+ */
}
- (void)windowDidMove:(NSNotification *)notification
{
- // [window->nsgl.context update];
+ /*
+ [window->nsgl.context update];
- // int x, y;
- // _GodotPlatformGetWindowPos(window, &x, &y);
- // _GodotInputWindowPos(window, x, y);
+ int x, y;
+ _GodotPlatformGetWindowPos(window, &x, &y);
+ _GodotInputWindowPos(window, x, y);
- //if (window->cursorMode == Godot_CURSOR_DISABLED)
- // centerCursor(window);
+ if (window->cursorMode == Godot_CURSOR_DISABLED)
+ centerCursor(window);
+ */
}
- (void)windowDidBecomeKey:(NSNotification *)notification
{
- // _GodotInputWindowFocus(window, GL_TRUE);
- // _GodotPlatformSetCursorMode(window, window->cursorMode);
+ //_GodotInputWindowFocus(window, GL_TRUE);
+ //_GodotPlatformSetCursorMode(window, window->cursorMode);
if (OS_OSX::singleton->get_main_loop())
OS_OSX::singleton->get_main_loop()->notification(MainLoop::NOTIFICATION_WM_FOCUS_IN);
}
- (void)windowDidResignKey:(NSNotification *)notification
{
- // _GodotInputWindowFocus(window, GL_FALSE);
- // _GodotPlatformSetCursorMode(window, Godot_CURSOR_NORMAL);
+ //_GodotInputWindowFocus(window, GL_FALSE);
+ //_GodotPlatformSetCursorMode(window, Godot_CURSOR_NORMAL);
if (OS_OSX::singleton->get_main_loop())
OS_OSX::singleton->get_main_loop()->notification(MainLoop::NOTIFICATION_WM_FOCUS_OUT);
}
@@ -273,16 +277,18 @@ static int button_mask=0;
+ (void)initialize
{
- if (self == [GodotContentView class])
- {
- /* if (_glfw.ns.cursor == nil)
+ if (self == [GodotContentView class])
{
- NSImage* data = [[NSImage alloc] initWithSize:NSMakeSize(1, 1)];
- _glfw.ns.cursor = [[NSCursor alloc] initWithImage:data
- hotSpot:NSZeroPoint];
- [data release];
- }*/
- }
+ /*
+ if (_glfw.ns.cursor == nil)
+ {
+ NSImage* data = [[NSImage alloc] initWithSize:NSMakeSize(1, 1)];
+ _glfw.ns.cursor = [[NSCursor alloc] initWithImage:data
+ hotSpot:NSZeroPoint];
+ [data release];
+ }
+ */
+ }
}
- (id)init
@@ -993,7 +999,7 @@ void OS_OSX::initialize(const VideoMode& p_desired,int p_video_driver,int p_audi
[window_object setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary];
}
-// [window_object setTitle:[NSString stringWithUTF8String:"GodotEnginies"]];
+ //[window_object setTitle:[NSString stringWithUTF8String:"GodotEnginies"]];
[window_object setContentView:window_view];
[window_object setDelegate:window_delegate];
[window_object setAcceptsMouseMovedEvents:YES];
@@ -1019,7 +1025,7 @@ void OS_OSX::initialize(const VideoMode& p_desired,int p_video_driver,int p_audi
ADD_ATTR(NSOpenGLPFADoubleBuffer);
ADD_ATTR(NSOpenGLPFAClosestPolicy);
-// we now need OpenGL 3 or better, maybe even change this to 3_3Core ?
+ //we now need OpenGL 3 or better, maybe even change this to 3_3Core ?
ADD_ATTR2(NSOpenGLPFAOpenGLProfile, NSOpenGLProfileVersion3_2Core);
ADD_ATTR2(NSOpenGLPFAColorSize, colorBits);
@@ -1083,15 +1089,16 @@ void OS_OSX::initialize(const VideoMode& p_desired,int p_video_driver,int p_audi
RasterizerGLES3::register_config();
RasterizerGLES3::make_current();
-// rasterizer = instance_RasterizerGLES2();
-// visual_server = memnew( VisualServerRaster(rasterizer) );
+ //rasterizer = instance_RasterizerGLES2();
+ //visual_server = memnew( VisualServerRaster(rasterizer) );
visual_server = memnew( VisualServerRaster );
// FIXME: Reimplement threaded rendering? Or remove?
-// if (get_render_thread_mode()!=RENDER_THREAD_UNSAFE) {
-//
-// visual_server =memnew(VisualServerWrapMT(visual_server,get_render_thread_mode()==RENDER_SEPARATE_THREAD));
-// }
+ /*
+ if (get_render_thread_mode()!=RENDER_THREAD_UNSAFE) {
+ visual_server =memnew(VisualServerWrapMT(visual_server,get_render_thread_mode()==RENDER_SEPARATE_THREAD));
+ }
+ */
visual_server->init();
visual_server->cursor_set_visible(false, 0);
@@ -1175,7 +1182,7 @@ void OS_OSX::finalize() {
visual_server->finish();
memdelete(visual_server);
-// memdelete(rasterizer);
+ //memdelete(rasterizer);
physics_server->finish();
memdelete(physics_server);
@@ -1730,10 +1737,10 @@ void OS_OSX::run() {
set_window_fullscreen(true);
}
-// uint64_t last_ticks=get_ticks_usec();
+ //uint64_t last_ticks=get_ticks_usec();
-// int frames=0;
-// uint64_t frame=0;
+ //int frames=0;
+ //uint64_t frame=0;
while (!force_quit) {
diff --git a/platform/server/os_server.cpp b/platform/server/os_server.cpp
index e35ad1adf8..6b91a5ce77 100644
--- a/platform/server/os_server.cpp
+++ b/platform/server/os_server.cpp
@@ -103,9 +103,11 @@ void OS_Server::finalize() {
spatial_sound_2d_server->finish();
memdelete(spatial_sound_2d_server);
- //if (debugger_connection_console) {
-// memdelete(debugger_connection_console);
-//}
+ /*
+ if (debugger_connection_console) {
+ memdelete(debugger_connection_console);
+ }
+ */
memdelete(sample_manager);
diff --git a/platform/server/os_server.h b/platform/server/os_server.h
index 6aa1b9e14b..f7fe586b1b 100644
--- a/platform/server/os_server.h
+++ b/platform/server/os_server.h
@@ -51,7 +51,7 @@
class OS_Server : public OS_Unix {
-// Rasterizer *rasterizer;
+ //Rasterizer *rasterizer;
VisualServer *visual_server;
VideoMode current_videomode;
List<String> args;
diff --git a/platform/uwp/os_uwp.cpp b/platform/uwp/os_uwp.cpp
index 34977bc048..9dd745716e 100644
--- a/platform/uwp/os_uwp.cpp
+++ b/platform/uwp/os_uwp.cpp
@@ -412,9 +412,11 @@ void OSUWP::finalize() {
spatial_sound_2d_server->finish();
memdelete(spatial_sound_2d_server);
- //if (debugger_connection_console) {
-// memdelete(debugger_connection_console);
-//}
+ /*
+ if (debugger_connection_console) {
+ memdelete(debugger_connection_console);
+ }
+ */
memdelete(sample_manager);
diff --git a/platform/windows/context_gl_win.cpp b/platform/windows/context_gl_win.cpp
index 6b60ade5f0..7a81dfef77 100644
--- a/platform/windows/context_gl_win.cpp
+++ b/platform/windows/context_gl_win.cpp
@@ -199,7 +199,7 @@ Error ContextGL_Win::initialize() {
}
wglSwapIntervalEXT = (PFNWGLSWAPINTERVALEXTPROC) wglGetProcAddress ("wglSwapIntervalEXT");
-// glWrapperInit(wrapper_get_proc_address);
+ //glWrapperInit(wrapper_get_proc_address);
return OK;
}
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index d88a545b5e..8910b23a2e 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -635,8 +635,10 @@ LRESULT OS_Windows::WndProc(HWND hWnd,UINT uMsg, WPARAM wParam, LPARAM lParam) {
gr_mem=alt_mem;
}
- //if (wParam==VK_WIN) TODO wtf is this?
- // meta_mem=uMsg==WM_KEYDOWN;
+ /*
+ if (wParam==VK_WIN) TODO wtf is this?
+ meta_mem=uMsg==WM_KEYDOWN;
+ */
} //fallthrough
@@ -1085,12 +1087,12 @@ void OS_Windows::initialize(const VideoMode& p_desired,int p_video_driver,int p_
visual_server = memnew( VisualServerRaster );
// FIXME: Reimplement threaded rendering? Or remove?
-// if (get_render_thread_mode()!=RENDER_THREAD_UNSAFE) {
-//
-// visual_server =memnew(VisualServerWrapMT(visual_server,get_render_thread_mode()==RENDER_SEPARATE_THREAD));
-// }
+ /*
+ if (get_render_thread_mode()!=RENDER_THREAD_UNSAFE) {
+ visual_server =memnew(VisualServerWrapMT(visual_server,get_render_thread_mode()==RENDER_SEPARATE_THREAD));
+ }
+ */
- //
physics_server = memnew( PhysicsServerSW );
physics_server->init();
@@ -1274,9 +1276,11 @@ void OS_Windows::finalize() {
spatial_sound_2d_server->finish();
memdelete(spatial_sound_2d_server);
- //if (debugger_connection_console) {
-// memdelete(debugger_connection_console);
-//}
+ /*
+ if (debugger_connection_console) {
+ memdelete(debugger_connection_console);
+ }
+ */
memdelete(sample_manager);
@@ -1608,7 +1612,7 @@ void OS_Windows::set_window_fullscreen(bool p_enabled){
*/
}
-// MoveWindow(hWnd,r.left,r.top,p_size.x,p_size.y,TRUE);
+ //MoveWindow(hWnd,r.left,r.top,p_size.x,p_size.y,TRUE);
}
@@ -1986,7 +1990,7 @@ Error OS_Windows::execute(const String& p_path, const List<String>& p_arguments,
argss+=String(" \"")+p_arguments[i]+"\"";
}
-// print_line("ARGS: "+argss);
+ //print_line("ARGS: "+argss);
//argss+"\"";
//argss+=" 2>nul";
diff --git a/platform/x11/context_gl_x11.cpp b/platform/x11/context_gl_x11.cpp
index 4adb47938c..39b704d2c4 100644
--- a/platform/x11/context_gl_x11.cpp
+++ b/platform/x11/context_gl_x11.cpp
@@ -88,7 +88,7 @@ Error ContextGL_X11::initialize() {
GLXCREATECONTEXTATTRIBSARBPROC glXCreateContextAttribsARB = NULL;
-// const char *extensions = glXQueryExtensionsString(x11_display, DefaultScreen(x11_display));
+ //const char *extensions = glXQueryExtensionsString(x11_display, DefaultScreen(x11_display));
glXCreateContextAttribsARB = (GLXCREATECONTEXTATTRIBSARBPROC)glXGetProcAddress((const GLubyte*)"glXCreateContextAttribsARB");
diff --git a/platform/x11/context_gl_x11.h b/platform/x11/context_gl_x11.h
index efe377ad92..efea700224 100644
--- a/platform/x11/context_gl_x11.h
+++ b/platform/x11/context_gl_x11.h
@@ -48,7 +48,7 @@ class ContextGL_X11 : public ContextGL {
ContextGL_X11_Private *p;
OS::VideoMode default_video_mode;
-// ::Colormap x11_colormap;
+ //::Colormap x11_colormap;
::Display *x11_display;
::Window& x11_window;
bool double_buffer;
diff --git a/platform/x11/key_mapping_x11.cpp b/platform/x11/key_mapping_x11.cpp
index 7b92ed95de..d25fe40c4d 100644
--- a/platform/x11/key_mapping_x11.cpp
+++ b/platform/x11/key_mapping_x11.cpp
@@ -90,8 +90,8 @@ static _XTranslatePair _xkeysym_to_keycode[]={
{ XK_Begin, KEY_CLEAR },
{ XK_Insert, KEY_INSERT },
{ XK_Delete, KEY_DELETE },
-// { XK_KP_Equal, KEY_EQUAL },
-// { XK_KP_Separator, KEY_COMMA },
+ //{ XK_KP_Equal, KEY_EQUAL },
+ //{ XK_KP_Separator, KEY_COMMA },
{ XK_KP_Decimal, KEY_KP_PERIOD },
{ XK_KP_Delete, KEY_KP_PERIOD },
{ XK_KP_Enter, KEY_KP_ENTER },
diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp
index c1eb550949..13e01ab6ac 100644
--- a/platform/x11/os_x11.cpp
+++ b/platform/x11/os_x11.cpp
@@ -474,9 +474,11 @@ void OS_X11::finalize() {
spatial_sound_2d_server->finish();
memdelete(spatial_sound_2d_server);
- //if (debugger_connection_console) {
-// memdelete(debugger_connection_console);
-//}
+ /*
+ if (debugger_connection_console) {
+ memdelete(debugger_connection_console);
+ }
+ */
#ifdef JOYDEV_ENABLED
memdelete(joypad);
@@ -1923,10 +1925,10 @@ void OS_X11::run() {
main_loop->init();
-// uint64_t last_ticks=get_ticks_usec();
+ //uint64_t last_ticks=get_ticks_usec();
-// int frames=0;
-// uint64_t frame=0;
+ //int frames=0;
+ //uint64_t frame=0;
while (!force_quit) {