Java tutorial
//package com.java2s; //License from project: Open Source License import javax.swing.JPanel; import javax.swing.JLabel; import java.awt.BorderLayout; import javax.swing.SwingConstants; public class Main { public static void setupNowLoadingPanel(JPanel panel) { JLabel loading = new JLabel("Loading...", SwingConstants.CENTER); panel.setLayout(new BorderLayout()); panel.add(loading, BorderLayout.CENTER); panel.revalidate(); panel.repaint(); } }