Class RealmsDownloadLatestWorldScreen

All Implemented Interfaces:
ContainerEventHandler, GuiEventListener, Renderable, TabOrderedElement

public class RealmsDownloadLatestWorldScreen extends RealmsScreen
  • Field Details

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • DOWNLOAD_LOCK

      private static final ReentrantLock DOWNLOAD_LOCK
    • BAR_WIDTH

      private static final int BAR_WIDTH
      See Also:
    • BAR_TOP

      private static final int BAR_TOP
      See Also:
    • BAR_BOTTOM

      private static final int BAR_BOTTOM
      See Also:
    • BAR_BORDER

      private static final int BAR_BORDER
      See Also:
    • lastScreen

      private final Screen lastScreen
    • worldDownload

      private final WorldDownload worldDownload
    • downloadTitle

      private final Component downloadTitle
    • narrationRateLimiter

      private final com.google.common.util.concurrent.RateLimiter narrationRateLimiter
    • cancelButton

      private Button cancelButton
    • worldName

      private final String worldName
    • downloadStatus

      private final RealmsDownloadLatestWorldScreen.DownloadStatus downloadStatus
    • errorMessage

      @Nullable private volatile Component errorMessage
    • status

      private volatile Component status
    • progress

      @Nullable private volatile String progress
    • cancelled

      private volatile boolean cancelled
    • showDots

      private volatile boolean showDots
    • finished

      private volatile boolean finished
    • extracting

      private volatile boolean extracting
    • previousWrittenBytes

      @Nullable private Long previousWrittenBytes
    • previousTimeSnapshot

      @Nullable private Long previousTimeSnapshot
    • bytesPersSecond

      private long bytesPersSecond
    • animTick

      private int animTick
    • DOTS

      private static final String[] DOTS
    • dotIndex

      private int dotIndex
    • checked

      private boolean checked
    • callback

      private final it.unimi.dsi.fastutil.booleans.BooleanConsumer callback
  • Constructor Details

    • RealmsDownloadLatestWorldScreen

      public RealmsDownloadLatestWorldScreen(Screen p_88625_, WorldDownload p_88626_, String p_88627_, it.unimi.dsi.fastutil.booleans.BooleanConsumer p_88628_)
  • Method Details

    • init

      public void init()
      Overrides:
      init in class Screen
    • checkDownloadSize

      private void checkDownloadSize()
    • getContentLength

      private long getContentLength(String p_88647_)
    • tick

      public void tick()
      Overrides:
      tick in class Screen
    • createProgressNarrationMessage

      private Component createProgressNarrationMessage()
    • onClose

      public void onClose()
      Overrides:
      onClose in class Screen
    • render

      public void render(GuiGraphics p_282124_, int p_88635_, int p_88636_, float p_88637_)
      Specified by:
      render in interface Renderable
      Overrides:
      render in class Screen
    • drawDots

      private void drawDots(GuiGraphics p_281948_)
    • drawProgressBar

      private void drawProgressBar(GuiGraphics p_281556_)
    • drawDownloadSpeed

      private void drawDownloadSpeed(GuiGraphics p_282236_)
    • drawDownloadSpeed0

      private void drawDownloadSpeed0(GuiGraphics p_283338_, long p_281931_)
    • downloadSave

      private void downloadSave()
    • downloadCancelled

      private void downloadCancelled()