recentChat: trying to fix scrollbar error on sirus wow

This commit is contained in:
Sattva
2025-04-14 23:50:30 +03:00
parent 646df4c090
commit c2dfbe9b91
2 changed files with 61 additions and 45 deletions
+54 -44
View File
@@ -1,49 +1,59 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/" <Ui xmlns="http://www.blizzard.com/wow/ui/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.blizzard.com/wow/ui/..\FrameXML\UI.xsd"> xsi:schemaLocation="http://www.blizzard.com/wow/ui/..\FrameXML\UI.xsd">
<ScrollFrame name="Leatrix_InputScrollFrameTemplate" virtual="true"> <ScrollFrame name="Leatrix_InputScrollFrameTemplate" virtual="true">
<KeyValues> <KeyValues>
<KeyValue key="maxLetters" value="0" type="number"/> <KeyValue key="maxLetters" value="0" type="number"/>
</KeyValues> </KeyValues>
<Layers> <Frames>
<Layer level="OVERLAY"> <Slider name="$parentScrollBar" inherits="UIPanelScrollBarTemplate" parentKey="ScrollBar" hidden="true">
<FontString inherits="GameFontDisableLarge" parentKey="CharCount"> <Anchors>
<Anchors> <Anchor point="TOPLEFT" relativePoint="TOPRIGHT" x="6" y="-16"/>
<Anchor point="BOTTOMRIGHT" x="-6" y="0"/> <Anchor point="BOTTOMLEFT" relativePoint="BOTTOMRIGHT" x="6" y="16"/>
</Anchors> </Anchors>
</FontString> </Slider>
</Layer> </Frames>
</Layers>
<Scripts> <Layers>
<OnLoad function="InputScrollFrame_OnLoad"/> <Layer level="OVERLAY">
<OnMouseDown function="InputScrollFrame_OnMouseDown"/> <FontString inherits="GameFontDisableLarge" parentKey="CharCount">
</Scripts> <Anchors>
<ScrollChild> <Anchor point="BOTTOMRIGHT" x="-6" y="0"/>
<EditBox parentKey="EditBox" multiLine="true" countInvisibleLetters="true" autoFocus="false"> </Anchors>
<Size x="1" y="1"/> </FontString>
<Anchors> </Layer>
<Anchor point="TOPLEFT"/> </Layers>
</Anchors> <Scripts>
<Layers> <OnLoad function="InputScrollFrame_OnLoad"/>
<Layer level="BORDER"> <OnMouseDown function="InputScrollFrame_OnMouseDown"/>
<FontString parentKey="Instructions" inherits="GameFontNormalSmall" justifyH="LEFT" justifyV="TOP"> </Scripts>
<Anchors> <ScrollChild>
<Anchor point="TOPLEFT" x="0" y="0"/> <EditBox parentKey="EditBox" multiLine="true" countInvisibleLetters="true" autoFocus="false">
</Anchors> <Size x="1" y="1"/>
<Color r="0.35" g="0.35" b="0.35"/> <Anchors>
</FontString> <Anchor point="TOPLEFT"/>
</Layer> </Anchors>
</Layers> <Layers>
<Scripts> <Layer level="BORDER">
<OnTabPressed function="InputScrollFrame_OnTabPressed"/> <FontString parentKey="Instructions" inherits="GameFontNormalSmall" justifyH="LEFT"
<OnTextChanged function="InputScrollFrame_OnTextChanged"/> justifyV="TOP">
<OnCursorChanged function="ScrollingEdit_OnCursorChanged"/> <Anchors>
<OnUpdate function="InputScrollFrame_OnUpdate"/> <Anchor point="TOPLEFT" x="0" y="0"/>
<OnEscapePressed function="InputScrollFrame_OnEscapePressed"/> </Anchors>
</Scripts> <Color r="0.35" g="0.35" b="0.35"/>
<FontString inherits="GameFontHighlightSmall"/> </FontString>
</EditBox> </Layer>
</ScrollChild> </Layers>
</ScrollFrame> <Scripts>
<OnTabPressed function="InputScrollFrame_OnTabPressed"/>
<OnTextChanged function="InputScrollFrame_OnTextChanged"/>
<OnCursorChanged function="ScrollingEdit_OnCursorChanged"/>
<OnUpdate function="InputScrollFrame_OnUpdate"/>
<OnEscapePressed function="InputScrollFrame_OnEscapePressed"/>
</Scripts>
<FontString inherits="GameFontHighlightSmall"/>
</EditBox>
</ScrollChild>
</ScrollFrame>
</Ui> </Ui>
+7 -1
View File
@@ -13258,7 +13258,8 @@
-- Create title bar -- Create title bar
local titleFrame = CreateFrame("ScrollFrame", nil, editFrame, "Leatrix_InputScrollFrameTemplate") local titleFrame = CreateFrame("ScrollFrame", "LeatrixTitleFrame", editFrame, "Leatrix_InputScrollFrameTemplate")
if titleFrame.CharCount then titleFrame.CharCount:Hide() end
titleFrame:ClearAllPoints() titleFrame:ClearAllPoints()
titleFrame:SetPoint("TOP", 0, 40) titleFrame:SetPoint("TOP", 0, 40)
titleFrame:SetSize(600, 36) titleFrame:SetSize(600, 36)
@@ -13338,6 +13339,11 @@
scrollFrame:SetPoint("BOTTOMRIGHT", editFrame, "BOTTOMRIGHT", -34, 8) scrollFrame:SetPoint("BOTTOMRIGHT", editFrame, "BOTTOMRIGHT", -34, 8)
scrollFrame:EnableMouseWheel(true) scrollFrame:EnableMouseWheel(true)
-- Create CharCount font string to avoid lua error for it not existing on WoW Sirus
scrollFrame.CharCount = scrollFrame:CreateFontString(nil, "OVERLAY", "GameFontDisableLarge")
scrollFrame.CharCount:Hide()
-- Set the existing edit box as the scroll child -- Set the existing edit box as the scroll child
scrollFrame:SetScrollChild(editBox) scrollFrame:SetScrollChild(editBox)