Skip to content

Commit

Permalink
android deps: Finish removal of react-native-orientation.
Browse files Browse the repository at this point in the history
In 0d5a19a, for zulip#4147, we forgot to remove some Android
configuration specific to `react-native-orientation` in
MainActivity.java [1], added in 3149c9d. So, remove it.

It appears that the iOS configuration at the
`react-native-orientation` doc was never done, so there's nothing to
do for that.

Greg pointed out that this override was replicated in
ReceiveShareActivity.kt when that file was created (in 0b84717)
and that he was puzzled by it while reviewing zulip#4124 and supposed it
might be generic RN boilerplate. Now that we've identified it,
remove it.

[1]: https://github.com/yamill/react-native-orientation#configuration
  • Loading branch information
chrisbobbe committed Jun 12, 2020
1 parent d61ef3c commit 065ba64
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 18 deletions.
10 changes: 0 additions & 10 deletions android/app/src/main/java/com/zulipmobile/MainActivity.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
package com.zulipmobile;

import android.content.Intent;
import android.content.res.Configuration;
import android.os.Bundle;
import android.webkit.WebView;
import com.facebook.react.ReactActivity;
Expand All @@ -22,12 +20,4 @@ protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
WebView.setWebContentsDebuggingEnabled(true);
}

@Override
public void onConfigurationChanged(Configuration newConfig) {
super.onConfigurationChanged(newConfig);
Intent intent = new Intent("onConfigurationChanged");
intent.putExtra("newConfig", newConfig);
this.sendBroadcast(intent);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package com.zulipmobile.sharing

import android.content.Context
import android.content.Intent
import android.content.res.Configuration
import android.net.Uri
import android.os.Bundle
import android.util.Log
Expand Down Expand Up @@ -105,13 +104,6 @@ class ReceiveShareActivity : ReactActivity() {
}
return params
}

override fun onConfigurationChanged(newConfig: Configuration) {
super.onConfigurationChanged(newConfig)
val intent = Intent("onConfigurationChanged")
intent.putExtra("newConfig", newConfig)
this.sendBroadcast(intent)
}
}

class ShareParamsParseException(errorMessage: String) : RuntimeException(errorMessage)

0 comments on commit 065ba64

Please sign in to comment.