Class PackSelectionScreen
java.lang.Object
net.minecraft.client.gui.components.events.AbstractContainerEventHandler
net.minecraft.client.gui.screens.Screen
net.minecraft.client.gui.screens.packs.PackSelectionScreen
- All Implemented Interfaces:
ContainerEventHandler, GuiEventListener, Renderable, TabOrderedElement
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class Screen
Screen.NarratableSearchResult -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Componentprivate @Nullable TransferableSelectionListprivate static final Identifierprivate static final Componentprivate @Nullable Buttonprivate static final Componentprivate static final intprivate final HeaderAndFooterLayoutprivate static final intprivate static final org.slf4j.Loggerprivate final PackSelectionModelprivate static final Componentprivate final Pathprivate final Map<String, Identifier> private static final intprivate @Nullable EditBoxprivate static final Componentprivate static final intprivate static final Componentprivate @Nullable TransferableSelectionListprivate longprivate @Nullable PackSelectionScreen.WatcherFields inherited from class Screen
FADE_IN_TIME, font, FOOTER_SEPARATOR, HEADER_SEPARATOR, height, INWORLD_FOOTER_SEPARATOR, INWORLD_HEADER_SEPARATOR, MENU_BACKGROUND, minecraft, narratorButton, renderables, screenExecutor, title, width -
Constructor Summary
ConstructorsConstructorDescriptionPackSelectionScreen(PackRepository repository, Consumer<PackRepository> output, Path packDir, Component title) -
Method Summary
Modifier and TypeMethodDescriptionprivate voidprotected static voidextractPackNames(Collection<Path> files) private voidfilterEntries(String value, Stream<PackSelectionModel.Entry> oldEntries, @Nullable TransferableSelectionList listToUpdate) private IdentifiergetPackIcon(Pack pack) protected voidinit()private IdentifierloadPackIcon(TextureManager textureManager, Pack pack) voidonClose()voidonFilesDrop(List<Path> files) private voidpopulateLists(@Nullable PackSelectionModel.EntryBase transferredEntry) private voidreload()protected voidprotected voidvoidtick()private voidupdateFilteredEntries(String value) Methods inherited from class Screen
added, addRenderableOnly, addRenderableWidget, addWidget, afterKeyboardAction, afterMouseAction, afterMouseMove, canInterruptWithAnotherScreen, changeFocus, children, clearFocus, clearWidgets, clickCommandAction, clickUrlAction, defaultHandleClickEvent, defaultHandleGameClickEvent, fadeWidgets, fillCrashDetails, findNarratableWidget, getBackgroundMusic, getFont, getMinecraft, getNarrationMessage, getRectangle, getTitle, getTooltipFromItem, getUsageNarration, handleDelayedNarration, init, insertText, isAllowedInPortal, isInGameUi, isMouseOver, isPauseScreen, isValidCharacterForName, keyPressed, panoramaShouldSpin, rebuildWidgets, removed, removeWidget, render, renderBackground, renderBlurredBackground, renderMenuBackground, renderMenuBackground, renderMenuBackgroundTexture, renderPanorama, renderTransparentBackground, renderWithTooltipAndSubtitles, resize, setInitialFocus, shouldCloseOnEsc, shouldNarrateNavigation, showsActiveEffects, triggerImmediateNarration, updateNarratedWidget, updateNarrationState, updateNarratorStatusMethods inherited from class AbstractContainerEventHandler
getFocused, isDragging, setDragging, setFocusedMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ContainerEventHandler
charTyped, getBorderForArrowNavigation, getChildAt, getCurrentFocusPath, isFocused, keyReleased, mouseClicked, mouseDragged, mouseReleased, mouseScrolled, nextFocusPath, setFocusedMethods inherited from interface GuiEventListener
mouseMoved, shouldTakeFocusAfterInteractionMethods inherited from interface TabOrderedElement
getTabOrderGroup
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
AVAILABLE_TITLE
-
SELECTED_TITLE
-
OPEN_PACK_FOLDER_TITLE
-
SEARCH
-
LIST_WIDTH
private static final int LIST_WIDTH- See Also:
-
HEADER_ELEMENT_SPACING
private static final int HEADER_ELEMENT_SPACING- See Also:
-
SEARCH_BOX_HEIGHT
private static final int SEARCH_BOX_HEIGHT- See Also:
-
DRAG_AND_DROP
-
DIRECTORY_BUTTON_TOOLTIP
-
RELOAD_COOLDOWN
private static final int RELOAD_COOLDOWN- See Also:
-
DEFAULT_ICON
-
layout
-
model
-
watcher
-
ticksToReload
private long ticksToReload -
availablePackList
-
selectedPackList
-
search
-
packDir
-
doneButton
-
packIcons
-
-
Constructor Details
-
PackSelectionScreen
public PackSelectionScreen(PackRepository repository, Consumer<PackRepository> output, Path packDir, Component title)
-
-
Method Details
-
onClose
-
closeWatcher
private void closeWatcher() -
init
-
setInitialFocus
protected void setInitialFocus()- Overrides:
setInitialFocusin classScreen
-
updateFilteredEntries
-
filterEntries
private void filterEntries(String value, Stream<PackSelectionModel.Entry> oldEntries, @Nullable TransferableSelectionList listToUpdate) -
repositionElements
protected void repositionElements()- Overrides:
repositionElementsin classScreen
-
tick
-
populateLists
-
reload
private void reload() -
copyPacks
-
onFilesDrop
- Overrides:
onFilesDropin classScreen
-
extractPackNames
-
loadPackIcon
-
getPackIcon
-