Reputation: 2340
I have simple custom view with EditText and the copy/paste popup is not showing on Oreo. It is working on Android 7, it is even working on my Emulator running Android 8 Oreo, but it is not working on real device with Android Oreo (Google Pixel, Nexus 5X). When I long press on my custom view with EditText, the popup menu with copy/paste options is not displayed at all on real device (again, it is working on Android 7 and lower and on Emulator running Oreo). But when I fill some text in the EditText, and then do a long press, the copy/paste popup show up even on Oreo on my device.
Really weird behaviour. I copied all my logic in my custom view so just the simple EditText is there and still no result. I think that maybe it is about new auto fill feature that breaks it down?
Upvotes: 3
Views: 867
Reputation: 125
If you have any method like this in your Application, please rename it.
protected int getUserId() {
return getCurrentUserRepository().getId();
}
Upvotes: -2
Reputation: 2340
So I found that the problem is, when the EditText has set negative side margin.
Sample layout that is not showing copy/paste popup on Android Oreo (real device only):
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="-4dp"
android:layout_marginRight="-4dp"/>
I created new issue: https://issuetracker.google.com/issues/65575880
Upvotes: 4