Nit Fixes

Signed-off-by: Priyank Shankar <shankarpriyank312002@gmail.com>
This commit is contained in:
Priyank Shankar 2022-08-29 20:31:53 +05:30
parent 689f500a01
commit 6a64389e90
5 changed files with 13 additions and 11 deletions

View file

@ -825,7 +825,7 @@
android:resource="@xml/automotive_app_desc"/>
<service
android:name="com.androidAuto.HelloWorldService"
android:name="com.androidAuto.AndroidAutoService"
android:exported="true">
<intent-filter>
<action android:name="androidx.car.app.CarAppService" />

View file

@ -10,10 +10,10 @@ import androidx.car.app.Screen;
import androidx.car.app.Session;
import androidx.car.app.validation.HostValidator;
public final class HelloWorldService extends CarAppService
public final class AndroidAutoService extends CarAppService
{
public HelloWorldService()
public AndroidAutoService()
{
// Exported services must have an empty public constructor.
}
@ -28,7 +28,7 @@ public final class HelloWorldService extends CarAppService
@NonNull
public Screen onCreateScreen(@Nullable Intent intent)
{
return new HelloWorldScreen(getCarContext());
return new MainScreen(getCarContext());
}
};
}

View file

@ -26,14 +26,14 @@ import com.mapswithme.maps.R;
import java.io.IOException;
public class HelloWorldScreen extends Screen implements SurfaceCallback
public class MainScreen extends Screen implements SurfaceCallback
{
private static final String TAG = HelloWorldScreen.class.getSimpleName();
private static final String TAG = MainScreen.class.getSimpleName();
@Nullable
private MapFragment mMapFragment;
private SurfaceCallback mSurfaceCallback;
public HelloWorldScreen(@NonNull CarContext carContext)
public MainScreen(@NonNull CarContext carContext)
{
super(carContext);

View file

@ -153,9 +153,11 @@ public class MapFragment extends BaseMwmFragment
@Override
public void surfaceCreated(SurfaceHolder surfaceHolder)
{ if(nativeIsEngineCreated()){
nativeDetachSurface(true);
}
{
if (MapFragment.nativeIsEngineCreated())
{
nativeDetachSurface(true);
}
if (isThemeChangingProcess())
{

View file

@ -255,7 +255,7 @@ public class MwmApplication extends Application implements AppBackgroundTracker.
{
Message m = Message.obtain(mMainLoopHandler, () -> nativeProcessTask(taskPointer));
m.obj = mMainQueueToken;
// mMainLoopHandler.sendMessage(m);
mMainLoopHandler.sendMessage(m);
}
@NonNull