Reputation: 116
I have come across https://github.com/google/talkback and I really like the idea of releasing the code to allow contributions.
However, when I tried building this project, I ran into errors on Android Studio.
I tried Import a project
and selecting this.
It's giving me errors because in the /talkback/src.../TalkbackService.java
the package name does not match the directory structure.
Is there a quick way I could go about fixing it?
I can run ./gradlew build
and it works perfectly, however, I don't get autocomplete in the Android studio project.
I've the latest android studio and the recommended Gradle versions.
Upvotes: 0
Views: 613
Reputation: 603
Ishan welcome to SO.
Adding the below code to the main activity or launcher activity in the talkback-master project - manifest file.
<category android:name="android.intent.category.LAUNCHER" />
I added to this activity in the manifest file. It did resolve the issue when I imported the project.
<activity
android:name="com.android.talkback.TalkBackPreferencesActivity"
android:exported="true"
android:label="@string/talkback_preferences_title"
android:launchMode="singleTop"
android:taskAffinity="com.google.android.accessibility.talkback.SettingsAffinity"
android:theme="@style/TalkBackSettings"
tools:ignore="ExportedActivity" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.accessibilityservice.SERVICE_SETTINGS" />
</intent-filter>
</activity>
Upvotes: 1