4

The sign-in popup windows didnt show up. The logcat said

  Could not find method android.view.View.getDisplay, referenced from method com.google.android.gms.internal.bn$b.b
   VFY: unable to resolve virtual method 3169: Landroid/view/View;.getDisplay ()Landroid/view/Display;
   VFY: replacing opcode 0x6e at 0x0009

I only tested on the real device, Samsung S3 which is Android 4.1.2 (API 16). The getDisplay() method required API 17. I tried "extends FragmentActivity" but there is no getDisplay() in support-v4 library. GamesClient.Builder.setViewForPopups() either not help. The Google Game Play Service should support since Android 2.2 as requirement said.

All my dev tool are up-to-date. google-play-lib 3.1.59 (744626-30), SDK 22.0.4.

Thank you very much.

ioipts
  • 41
  • 3
  • How do you integrate Google Play Services in your project? Are you using Eclipse or Android Studio/Gradle? – fasteque Oct 14 '13 at 15:03

3 Answers3

1

Try these steps:

  1. Right click the project, and choose Properties
  2. Go to Java Build Path-Order and Export.
  3. Tick 'Android Private Libraries' if you put your libs there or tick on your libs.

Then clean and build.

Nguyen Duc An
  • 193
  • 1
  • 4
1

Could you post a more complete log? There is a possibility that those lines are not the reason the sign-in window does not show up on your app (see this other post which shows those lines in the logs and yet was able to proceed).

Other things that might be helpful to you:

  • Following the instructions for the Type-A-Number sample, I was able to run it on my phone with Android 4.1.1.
  • The Google Play Services library that I have is newer than what you have (3.2.65 (834000-30)).
Community
  • 1
  • 1
Joe
  • 14,039
  • 2
  • 39
  • 49
  • @Nick (the bounty owner), to answer your question regarding API 17 usage in Google Play library: it is common for Dalvik to complain about missing methods in an APK. As long as we did not call those methods during the execution of our code (most likely using checks like `if (sdk < android.os.Build.VERSION_CODES.HONEYCOMB)` or something similar which I assume is done by Google), it should not be a problem. – Joe Oct 15 '13 at 20:40
0

Try to test on a different version of Android, as I also was facing some problems while testing my Apps on Android 4.1.2 particularly. Also, it would be better if you put some code where you are getting error. It helps to solve the issue much faster.

Also, please let us know if the issue is fixed. It will be useful for anyone else with the same problem.