Mercurial > wow > reaction
comparison ReAction.lua @ 77:da8ba8783924
- added revision updater to each code file
- Changed button/bar class mechanic to metatable-based
- Changed buttons to live within a sub-frame, to play nicely between show-empty-buttons and hidestates
- bar frame is now available only via accessor
- Changed some semantics with AddButton/PlaceButton
- Cleaned up action buttons options, fixed hide-when-empty option
- moved show-action-ID-label as a button method
- converted drag overlay from nested-frame to :Raise()
- fixed ReAction:SetConfigMode() to not call event when mode doesn't change
- Fixed ordering for dynamic state tab (always last)
| author | Flick <flickerstreak@gmail.com> |
|---|---|
| date | Mon, 23 Jun 2008 22:27:50 +0000 |
| parents | 06cd74bdc7da |
| children | 57f8151ea0f0 |
comparison
equal
deleted
inserted
replaced
| 76:c8c8610fd864 | 77:da8ba8783924 |
|---|---|
| 251 end | 251 end |
| 252 | 252 |
| 253 | 253 |
| 254 | 254 |
| 255 ------ API ------ | 255 ------ API ------ |
| 256 function ReAction:UpdateRevision(str) | |
| 257 local revision = tonumber(str:match("%d+")) | |
| 258 if revision and revision > ReAction.revision then | |
| 259 ReAction.revision = revision | |
| 260 end | |
| 261 end | |
| 262 | |
| 256 function ReAction:UserError(msg) | 263 function ReAction:UserError(msg) |
| 257 -- any user errors should be flashed to the UIErrorsFrame | 264 -- any user errors should be flashed to the UIErrorsFrame |
| 258 UIErrorsFrame:AddMessage(msg) | 265 UIErrorsFrame:AddMessage(msg) |
| 259 end | 266 end |
| 260 | 267 |
| 439 end | 446 end |
| 440 return opts | 447 return opts |
| 441 end | 448 end |
| 442 | 449 |
| 443 function ReAction:SetConfigMode( mode ) | 450 function ReAction:SetConfigMode( mode ) |
| 444 private.configMode = mode | 451 if mode ~= private.configMode then |
| 445 callbacks:Fire("OnConfigModeChanged", mode) | 452 private.configMode = mode |
| 453 callbacks:Fire("OnConfigModeChanged", mode) | |
| 454 end | |
| 446 end | 455 end |
| 447 | 456 |
| 448 function ReAction:GetConfigMode() | 457 function ReAction:GetConfigMode() |
| 449 return private.configMode | 458 return private.configMode |
| 450 end | 459 end |
