forked from j62/ctbrec
Show error dialog if login fails
This commit is contained in:
parent
4516b8d787
commit
f2ac9e3657
|
@ -12,6 +12,7 @@ import ctbrec.sites.bonga.BongaCams;
|
|||
import ctbrec.sites.bonga.BongaCamsHttpClient;
|
||||
import ctbrec.ui.SiteUI;
|
||||
import ctbrec.ui.TabProvider;
|
||||
import ctbrec.ui.controls.Dialogs;
|
||||
|
||||
public class BongaCamsSiteUi implements SiteUI {
|
||||
|
||||
|
@ -50,6 +51,7 @@ public class BongaCamsSiteUi implements SiteUI {
|
|||
new BongaCamsElectronLoginDialog(bongaCams.getHttpClient().getCookieJar());
|
||||
} catch (Exception e1) {
|
||||
LOG.error("Error logging in with external browser", e1);
|
||||
Dialogs.showError("Login error", "Couldn't login to " + bongaCams.getName(), e1);
|
||||
}
|
||||
|
||||
try {
|
||||
|
|
|
@ -12,6 +12,7 @@ import ctbrec.sites.cam4.Cam4;
|
|||
import ctbrec.sites.cam4.Cam4HttpClient;
|
||||
import ctbrec.ui.SiteUI;
|
||||
import ctbrec.ui.TabProvider;
|
||||
import ctbrec.ui.controls.Dialogs;
|
||||
import javafx.application.Platform;
|
||||
|
||||
public class Cam4SiteUi implements SiteUI {
|
||||
|
@ -52,6 +53,7 @@ public class Cam4SiteUi implements SiteUI {
|
|||
new Cam4ElectronLoginDialog(cam4.getHttpClient().getCookieJar());
|
||||
} catch (Exception e1) {
|
||||
LOG.error("Error logging in with external browser", e1);
|
||||
Dialogs.showError("Login error", "Couldn't login to " + cam4.getName(), e1);
|
||||
}
|
||||
|
||||
try {
|
||||
|
|
|
@ -12,6 +12,7 @@ import ctbrec.sites.jasmin.LiveJasmin;
|
|||
import ctbrec.sites.jasmin.LiveJasminHttpClient;
|
||||
import ctbrec.ui.SiteUI;
|
||||
import ctbrec.ui.TabProvider;
|
||||
import ctbrec.ui.controls.Dialogs;
|
||||
|
||||
public class LiveJasminSiteUi implements SiteUI {
|
||||
|
||||
|
@ -49,8 +50,9 @@ public class LiveJasminSiteUi implements SiteUI {
|
|||
try {
|
||||
//LiveJasminElectronLoginDialog dialog =
|
||||
new LiveJasminElectronLoginDialog(liveJasmin.getHttpClient().getCookieJar());
|
||||
} catch (IOException e1) {
|
||||
} catch (Exception e1) {
|
||||
LOG.error("Error logging in with external browser", e1);
|
||||
Dialogs.showError("Login error", "Couldn't login to " + liveJasmin.getName(), e1);
|
||||
}
|
||||
|
||||
try {
|
||||
|
|
Loading…
Reference in New Issue