2016-11-07 31 views
1

我正在將Auth0集成到我的Android應用程序中,並且需要允許用戶跳過/關閉Auth0登錄屏幕。但是,我無法顯示關閉按鈕。如何在Android中添加關閉標記到Auth0鎖定登錄屏幕

僅供參考我添加了一個截圖,顯示了我需要在我的應用程序中顯示的關閉按鈕。 enter image description here

這是我的代碼:

Auth0 auth0 = new Auth0(
    getString(R.string.auth0_client_id), getString(R.string.auth0_domain)); 

mLock = Lock.newBuilder(auth0, mCallback) 
    //Add parameters to the builder 
    .closable(true)// ITS NOT WORKING 
    .build(this); 

broadcastManager = LocalBroadcastManager.getInstance(this); 
broadcastManager.registerReceiver(receiver, 
    new IntentFilter("com.auth0.android.lock.action.Authentication")); 

回答

0

closable(true)在鎖定爲Android可用選項不會觸發關閉按鈕上的UI外觀。

按照related GitHub issue的說明,這是有意設計的,使其可關閉只是讓用戶以標準的Android方式返回。