This repository was archived by the owner on Aug 20, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +10
-7
lines changed
src/SignsInternal/PluginInfo Expand file tree Collapse file tree 2 files changed +10
-7
lines changed Original file line number Diff line number Diff line change 11local PluginGuiService = game :GetService (" PluginGuiService" )
22
3+ -- Find the PluginToolbar class, or create it if it doesn't exist
34local PluginToolbars = PluginGuiService :FindFirstChild (" PluginToolbars" )
45if PluginToolbars == nil then
56 PluginToolbars = Instance .new (" Folder" )
6- PluginToolbars .Archivable = false -- Prevent it from being included when saving the game or publishing it to roblox
7+ PluginToolbars .Archivable = false -- Don't want to save this to the place file
78 PluginToolbars .Name = " PluginToolbars"
89 PluginToolbars .Parent = PluginGuiService
910end
1011
1112local PluginToolbar = {}
12- local plugin = nil -- Unfortunately, even if this module is require()'d in a plugin context, this does not exist.
13+ local plugin = nil -- Unfortunately, even if this module is require()'d in a plugin context, this does not exist
1314
15+ -- Creates a new toolbar with the given name
1416local function CreateNewToolbar (name )
1517 local toolbar = plugin :CreateToolbar (name )
1618 toolbar .Name = name
1719 toolbar .Parent = PluginToolbars
1820 return toolbar
1921end
2022
23+ -- Creates a new button on the given toolbar
2124function PluginToolbar :CreateToolbar (name )
2225 assert (typeof (name ) == " string" , " Incorrect parameter type for param 'name' (expected string, got " .. typeof (name ) .. " )" )
2326 assert (# name > 0 , " Cannot have zero-length toolbar name." )
Original file line number Diff line number Diff line change @@ -3,13 +3,13 @@ local widgetInfo = DockWidgetPluginGuiInfo.new(
33 Enum .InitialDockState .Left , -- Widget will be initialized in left panel
44 false , -- Widget will be initially enabled
55 false , -- Don't override the previous enabled state
6- 300 , -- Default width of the floating window
7- 447 , -- Default height of the floating window
8- 280 , -- Minimum width of the floating window
9- 373 -- Minimum height of the floating window
6+ 275 , -- Default width of the floating window
7+ 655 , -- Default height of the floating window
8+ 165 , -- Minimum width of the floating window
9+ 415 -- Minimum height of the floating window
1010)
1111
12- -- Require plugin toolbar
12+ -- Require plugin toolbar so other plugins can share toolbar
1313local pluginToolbar = require (script .PluginToolbar )
1414pluginToolbar :SetPlugin (plugin )
1515
You can’t perform that action at this time.
0 commit comments