root/GHM/ghm.lua
| 609 | 611 | ||
|---|---|---|---|
662 | main.bb:Disable(); | 662 | main.bb:Disable(); |
663 | else | 663 | else |
664 | main.bb:Enable(); | 664 | main.bb:Enable(); |
665 | local f = _G[main:GetName().."_P"..main.currentPage-1]; | 665 | |
666 | if f then f:Hide(); end | ||
667 | end | 666 | end |
668 | main.bb:SetText("< Back"); | 667 | main.bb:SetText("< Back"); |
669 | if main.currentPage == main.numPages then | 668 | if main.currentPage == main.numPages then |
... | ... | ||
673 | local f = _G[main:GetName().."_P"..main.currentPage+1]; | 672 | local f = _G[main:GetName().."_P"..main.currentPage+1]; |
674 | if f then f:Hide(); end | 673 | if f then f:Hide(); end |
675 | end | 674 | end |
675 | |||
676 | for i = 1,main.numPages do | ||
677 | local f = _G[main:GetName().."_P"..i]; | ||
678 | if f then | ||
679 | f:Hide(); | ||
680 | end | ||
681 | end | ||
682 | |||
676 | local f = _G[main:GetName().."_P"..main.currentPage]; | 683 | local f = _G[main:GetName().."_P"..main.currentPage]; |
677 | if f then | 684 | if f then |
678 | f:Show(); | 685 | f:Show(); |
... | ... | ||
701 | end | 708 | end |
702 | main.UpdatePages() | 709 | main.UpdatePages() |
703 | end); | 710 | end); |
711 | |||
712 | main.SetPage = function(p) | ||
713 | main.currentPage = p; | ||
714 | main.UpdatePages(); | ||
715 | end | ||
704 | 716 | ||
705 | 717 | ||
706 | main.UpdatePages(); | 718 | main.UpdatePages(); |
Download diff