mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
[Android] Simplify onAttach for CPUSettingsFragment and VideoSettingsFragment
This commit is contained in:
@ -57,16 +57,8 @@ public final class CPUSettingsFragment extends PreferenceFragment
|
||||
{
|
||||
super.onAttach(activity);
|
||||
|
||||
// This makes sure that the container activity has implemented
|
||||
// the callback interface. If not, it throws an exception
|
||||
try
|
||||
{
|
||||
m_activity = activity;
|
||||
}
|
||||
catch (ClassCastException e)
|
||||
{
|
||||
throw new ClassCastException(activity.toString());
|
||||
}
|
||||
// Cache the activity instance.
|
||||
m_activity = activity;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -202,16 +202,8 @@ public final class VideoSettingsFragment extends PreferenceFragment
|
||||
{
|
||||
super.onAttach(activity);
|
||||
|
||||
// This makes sure that the container activity has implemented
|
||||
// the callback interface. If not, it throws an exception
|
||||
try
|
||||
{
|
||||
m_activity = activity;
|
||||
}
|
||||
catch (ClassCastException e)
|
||||
{
|
||||
throw new ClassCastException(activity.toString());
|
||||
}
|
||||
// Cache the activity instance.
|
||||
m_activity = activity;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Reference in New Issue
Block a user