Index: trunk/src/org/openstreetmap/josm/gui/download/DownloadDialog.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/download/DownloadDialog.java	(revision 14416)
+++ trunk/src/org/openstreetmap/josm/gui/download/DownloadDialog.java	(revision 14418)
@@ -11,4 +11,6 @@
 import java.awt.GridBagLayout;
 import java.awt.event.ActionEvent;
+import java.awt.event.ComponentAdapter;
+import java.awt.event.ComponentEvent;
 import java.awt.event.InputEvent;
 import java.awt.event.KeyEvent;
@@ -655,8 +657,26 @@
         private DownloadSourceSizingPolicy policy;
         private final JTabbedPane topComponent;
+        /**
+         * If the height was explicitly set by the user.
+         */
+        private boolean heightAdjustedExplicitly;
 
         DownloadDialogSplitPane(JTabbedPane newTopComponent, Component newBottomComponent) {
             super(VERTICAL_SPLIT, newTopComponent, newBottomComponent);
             this.topComponent = newTopComponent;
+
+            addComponentListener(new ComponentAdapter() {
+                @Override
+                public void componentResized(ComponentEvent e) {
+                    // doLayout is called automatically when the component size decreases
+                    // This seems to be the only way to call doLayout when the component size increases
+                    // We need this since we sometimes want to increase the top component size.
+                    revalidate();
+                }
+            });
+
+            addPropertyChangeListener(DIVIDER_LOCATION_PROPERTY, e -> {
+                heightAdjustedExplicitly = true;
+            });
         }
 
@@ -674,9 +694,14 @@
             // We cannot do this in the setDividerLocation, since the offset cannot be computed there.
             int offset = computeOffset();
-            if (policy.isHeightAdjustable()) {
+            if (policy.isHeightAdjustable() && heightAdjustedExplicitly) {
                 policy.storeHeight(Math.max(getDividerLocation() - offset, 0));
             }
-            super.setDividerLocation(policy.getComponentHeight() + offset);
+            // At least 30 pixel for map, if we have enough space
+            int maxValidDividerLocation = getHeight() > 150 ? getHeight() - 40 : getHeight();
+
+            super.setDividerLocation(Math.min(policy.getComponentHeight() + offset, maxValidDividerLocation));
             super.doLayout();
+            // Order is important (set this after setDividerLocation/doLayout called the listener)
+            this.heightAdjustedExplicitly = false;
         }
 
Index: trunk/src/org/openstreetmap/josm/gui/download/DownloadSourceSizingPolicy.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/download/DownloadSourceSizingPolicy.java	(revision 14416)
+++ trunk/src/org/openstreetmap/josm/gui/download/DownloadSourceSizingPolicy.java	(revision 14418)
@@ -3,4 +3,5 @@
 
 import java.awt.Component;
+import java.util.function.IntSupplier;
 
 import org.openstreetmap.josm.data.preferences.AbstractProperty;
@@ -67,16 +68,32 @@
 
         private final AbstractProperty<Integer> preference;
+        private IntSupplier minHeight;
 
         /**
          * Create a new {@link AdjustableDownloadSizePolicy}
-         * @param preference The preference key to use
+         * @param preference The preference to use
          */
         public AdjustableDownloadSizePolicy(AbstractProperty<Integer> preference) {
+            this(preference, () -> 1);
+        }
+
+        /**
+         * Create a new {@link AdjustableDownloadSizePolicy}
+         * @param preference The preference to use
+         * @param minHeight A supplier that gives the minimum height of the component. Must be positive or 0.
+         * @since 14418
+         */
+        public AdjustableDownloadSizePolicy(AbstractProperty<Integer> preference, IntSupplier minHeight) {
             this.preference = preference;
+            this.minHeight = minHeight;
         }
 
         @Override
         public int getComponentHeight() {
-            return Math.max(1, preference.get());
+            int computedMinHeight = this.minHeight.getAsInt();
+            if (computedMinHeight < 0) {
+                throw new IllegalStateException("Illegal minimum component height:" + computedMinHeight);
+            }
+            return Math.max(computedMinHeight, preference.get());
         }
 
Index: trunk/src/org/openstreetmap/josm/gui/download/OverpassDownloadSource.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/download/OverpassDownloadSource.java	(revision 14416)
+++ trunk/src/org/openstreetmap/josm/gui/download/OverpassDownloadSource.java	(revision 14418)
@@ -16,4 +16,5 @@
 
 import javax.swing.AbstractAction;
+import javax.swing.BorderFactory;
 import javax.swing.Icon;
 import javax.swing.JButton;
@@ -164,4 +165,5 @@
                 .forEach(button -> leftPanel.add(button, GBC.eol().anchor(GBC.CENTER)));
             leftPanel.add(new JLabel(), GBC.eol().fill(GBC.VERTICAL));
+            leftPanel.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
 
             add(leftPanel, BorderLayout.WEST);
@@ -285,5 +287,5 @@
         @Override
         public DownloadSourceSizingPolicy getSizingPolicy() {
-            return new AdjustableDownloadSizePolicy(PANEL_SIZE_PROPERTY);
+            return new AdjustableDownloadSizePolicy(PANEL_SIZE_PROPERTY, () -> 50);
         }
 
