Skip to content
This repository was archived by the owner on Apr 16, 2022. It is now read-only.

A solution for Bug #798 #851

Merged
merged 2 commits into from
Mar 9, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/org/opendatakit/briefcase/ui/pull/PullPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@

import java.util.Optional;
import javax.swing.JPanel;
import javax.swing.SwingUtilities;

import org.bushe.swing.event.EventBus;
import org.bushe.swing.event.annotation.AnnotationProcessor;
import org.bushe.swing.event.annotation.EventSubscriber;
Expand Down Expand Up @@ -69,6 +71,7 @@ private PullPanel(TransferPanelForm<PullSource> view, TransferForms forms, Brief

// Register callbacks to view events
view.onSelect(source -> {
view.setWorking();
this.source = Optional.of(source);
source.storeSourcePrefs(tabPreferences, getStorePasswordsConsentProperty());
onSource(view, forms, source);
Expand Down Expand Up @@ -125,10 +128,12 @@ private void onSource(TransferPanelForm view, TransferForms forms, PullSource<?>
JobsRunner.launchAsync(
run(__ -> {
forms.load(source.getFormList());
SwingUtilities.invokeLater(view::unsetWorking);
view.refresh();
updateActionButtons();
}),
cause -> {
SwingUtilities.invokeLater(view::unsetWorking);
log.warn("Unable to load form list from {}", source.getDescription(), cause);
errorMessage("Error Loading Forms", "Briefcase wasn't able to load forms using the configured source. Try Reload or Reset.");
}
Expand Down