uui/source/authfallbackdlg.cxx | 9 +++++++++ uui/source/authfallbackdlg.hxx | 2 ++ uui/uiconfig/ui/authfallback.ui | 26 ++++++++++++++++++++++++-- 3 files changed, 35 insertions(+), 2 deletions(-)
New commits: commit 5dee1106703a14c0128880736db77cd7507df776 Author: Szymon KÅos <eszka...@gmail.com> Date: Mon May 23 19:49:31 2016 +0200 Google 2FA: better info for user Google sends SMS with code in format "G-XXXXXX". User should enter only numbers wihout "G-". + added "G-" label which is shown in the Google authentication code request before PIN field Change-Id: I8eaecbbe7b8803269444f947e97ee67c33db61b2 diff --git a/uui/source/authfallbackdlg.cxx b/uui/source/authfallbackdlg.cxx index a6383d1..db0448e 100644 --- a/uui/source/authfallbackdlg.cxx +++ b/uui/source/authfallbackdlg.cxx @@ -23,6 +23,7 @@ AuthFallbackDlg::AuthFallbackDlg(Window* pParent, const OUString& instructions, get( m_pEDCode, "code" ); get( m_pBTOk, "ok" ); get( m_pBTCancel, "cancel" ); + get( m_pFTGooglePrefixLabel, "google_prefix_label" ); m_pBTOk->SetClickHdl( LINK( this, AuthFallbackDlg, OKHdl) ); m_pBTCancel->SetClickHdl( LINK( this, AuthFallbackDlg, CancelHdl) ); @@ -30,9 +31,17 @@ AuthFallbackDlg::AuthFallbackDlg(Window* pParent, const OUString& instructions, m_pTVInstructions->SetText( instructions ); if( url.isEmpty() ) + { + // Google 2FA + m_pFTGooglePrefixLabel->Show(); m_pEDUrl->Hide(); + } else + { + // OneDrive + m_pFTGooglePrefixLabel->Hide(); m_pEDUrl->SetText( url ); + } } AuthFallbackDlg::~AuthFallbackDlg() diff --git a/uui/source/authfallbackdlg.hxx b/uui/source/authfallbackdlg.hxx index b90bb15..9e5eb52 100644 --- a/uui/source/authfallbackdlg.hxx +++ b/uui/source/authfallbackdlg.hxx @@ -14,6 +14,7 @@ #include <vcl/dialog.hxx> #include <vcl/edit.hxx> #include <vcl/vclmedit.hxx> +#include <vcl/fixed.hxx> class AuthFallbackDlg : public ModalDialog @@ -24,6 +25,7 @@ private: VclPtr<Edit> m_pEDCode; VclPtr<PushButton> m_pBTOk; VclPtr<PushButton> m_pBTCancel; + VclPtr<FixedText> m_pFTGooglePrefixLabel; public: AuthFallbackDlg(Window* pParent, const OUString& instructions, diff --git a/uui/uiconfig/ui/authfallback.ui b/uui/uiconfig/ui/authfallback.ui index 6c99edf..dbeb5b5 100644 --- a/uui/uiconfig/ui/authfallback.ui +++ b/uui/uiconfig/ui/authfallback.ui @@ -92,10 +92,32 @@ </packing> </child> <child> - <object class="GtkEntry" id="code"> + <object class="GtkBox" id="box1"> <property name="visible">True</property> <property name="can_focus">False</property> - <property name="invisible_char">â</property> + <child> + <object class="GtkLabel" id="google_prefix_label"> + <property name="can_focus">False</property> + <property name="label" translatable="yes">G-</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">0</property> + </packing> + </child> + <child> + <object class="GtkEntry" id="code"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="invisible_char">â</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">1</property> + </packing> + </child> </object> <packing> <property name="expand">False</property>
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits