10000 bumped to 0.9.12 and removed the registerCallbacks method · crankycoder/fxa-android@a0d2836 · GitHub
[go: up one dir, main page]

Skip to content

Commit a0d2836

Browse files
committed
bumped to 0.9.12 and removed the registerCallbacks method
1 parent 0cf9ee4 commit a0d2836

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

android/src/main/java/org/mozilla/firefoxaccounts/MainApp.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,7 @@ public void onCreate(Bundle savedInstanceState) {
4040

4141
String app_name = getResources().getString(R.string.app_name);
4242
FxAGlobals fxa = new FxAGlobals();
43-
44-
fxa.registerCallbacks((IFxACallbacks) this);
45-
46-
fxa.startIntentListening(this, app_name);
43+
fxa.startIntentListening((Context)this, (IFxACallbacks) this, app_name);
4744

4845
setContentView(R.layout.appmainexample);
4946
}

libraries/fxa/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// each of the version numbers must be 0-99
22
def versionMajor = 0
33
def versionMinor = 9 // minor feature releases
4-
def versionPatch = 11 // This should be bumped for hot fixes
4+
def versionPatch = 12 // This should be bumped for hot fixes
55

66
// Double check the versioning
77
for (versionPart in [versionPatch, versionMinor, versionMajor]) {

libraries/fxa/src/main/java/org/mozilla/accounts/fxa/FxAGlobals.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,18 @@ public void onReceive(Context context, Intent intent) {
5050
};
5151
private IFxACallbacks callbackSite = null;
5252

53-
public void startIntentListening(Context ctx, String app_name) {
53+
public void startIntentListening(Context ctx, IFxACallbacks iFxACallbacks, String app_name) {
5454
// Clobber the FxAGlobals so that the user-agent for the FxA client will be sensible
5555
FxAGlobals.appVersionName = BuildConfig.VERSION_NAME;
5656
FxAGlobals.appVersionCode = BuildConfig.VERSION_CODE;
5757
FxAGlobals.appName = app_name;
5858

59+
callbackSite = iFxACallbacks;
60+
5961
IntentFilter intentFilter = new IntentFilter();
6062
Intents.registerFxaIntents(intentFilter);
6163

62-
LocalBroadcastManager
63-
.getInstance(ctx.getApplicationContext())
64+
LocalBroadcastManager.getInstance(ctx.getApplicationContext())
6465
.registerReceiver(callbackReceiver, intentFilter);
6566
}
6667

@@ -150,9 +151,6 @@ private void processDisplayNameWrite(Intent intent, boolean success) {
150151
callbackSite.processDisplayNameWrite();
151152
}
152153

153-
public void registerCallbacks(IFxACallbacks iFxACallbacks) {
154-
callbackSite = iFxACallbacks;
155-
}
156154
}
157155

158156

0 commit comments

Comments
 (0)
0