-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
3.1.3 discord 1 #1
base: master
Are you sure you want to change the base?
Conversation
955e447
to
e3ff091
Compare
fun ignoreAutoRotate(ignoreAutoRotate: Boolean) { | ||
this.autoRotateIgnored = ignoreAutoRotate | ||
this.maybeLockToPortrait() | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New API surface to disable the default behavior of respecting the auto-rotate setting.
private const val INTENT_VALUE_KEY = "newConfig" | ||
|
||
@Suppress("unused") | ||
fun sendBroadcast(activity: Activity, newConfig: Configuration) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New config method caller can use to report configuration that does not leak magic strings.
import com.facebook.react.bridge.LifecycleEventListener | ||
import com.facebook.react.bridge.ReactContext | ||
|
||
internal class OrientationAutoRotateListener( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Observer for when the auto rotate setting is toggled.
* Android - Emit orientation change event on host resume * Cleanup code, PR feedback * Only allow PORTRAIT and LANDSCAPE when receiving rotation event * Unify logic in OrientationConfigListener
6e133ba
to
1f85c94
Compare
Kotlin
.ignoreAutoRotate
).OrientationConfigListener.sendBroadcast
).Our
package.json
is pointing to the latest commit at: e3ff091