Mercurial > wow > wowdb-profiler
comparison Comments.lua @ 272:e9670d6c6bf1
Added keybinding for comment system, disabling the MiniMap/LDB icon for now (or indefinitely).
author | James D. Callahan III <jcallahan@curse.com> |
---|---|
date | Fri, 22 Mar 2013 10:48:39 -0500 |
parents | fbd94a0be29c |
children | ac6163ed8330 |
comparison
equal
deleted
inserted
replaced
271:fbd94a0be29c | 272:e9670d6c6bf1 |
---|---|
285 display:SetLineScript(line, "OnMouseUp", CreateComment, CreateQuestComment) | 285 display:SetLineScript(line, "OnMouseUp", CreateComment, CreateQuestComment) |
286 end | 286 end |
287 end | 287 end |
288 | 288 |
289 if display:GetLineCount() == 3 then | 289 if display:GetLineCount() == 3 then |
290 display = display:Release() | |
290 WDP:Print("There are no possible comment subjects.") | 291 WDP:Print("There are no possible comment subjects.") |
291 return | 292 return |
292 end | 293 end |
293 display:Show() | 294 display:Show() |
294 end | 295 end |
296 | |
297 WDP.ShowPossibleSubjects = ShowPossibleSubjects -- For Keybinding. | |
295 end -- do-block | 298 end -- do-block |
296 | 299 |
297 -- METHODS ------------------------------------------------------------ | 300 -- METHODS ------------------------------------------------------------ |
298 | 301 |
299 function private.ProcessCommentCommand(arg) | 302 function private.ProcessCommentCommand(arg) |
529 edit_box:SetText("") | 532 edit_box:SetText("") |
530 _G.HideUIPanel(panel) | 533 _G.HideUIPanel(panel) |
531 end) | 534 end) |
532 panel.submitButton = submit | 535 panel.submitButton = submit |
533 | 536 |
534 local data_obj = LibStub("LibDataBroker-1.1"):NewDataObject(ADDON_NAME, { | 537 -- local data_obj = LibStub("LibDataBroker-1.1"):NewDataObject(ADDON_NAME, { |
535 type = "data source", | 538 -- type = "data source", |
536 label = ADDON_NAME, | 539 -- label = ADDON_NAME, |
537 text = " ", | 540 -- text = " ", |
538 icon = [[Interface\CHATFRAME\UI-ChatIcon-Chat-Up]], | 541 -- icon = [[Interface\CHATFRAME\UI-ChatIcon-Chat-Up]], |
539 OnClick = function(self, button, down) | 542 -- OnClick = function(self, button, down) |
540 ShowPossibleSubjects(self) | 543 -- ShowPossibleSubjects(self) |
541 end, | 544 -- end, |
542 OnTooltipShow = function(self) | 545 -- OnTooltipShow = function(self) |
543 self:AddLine(_G.CLICK_TO_ENTER_COMMENT) | 546 -- self:AddLine(_G.CLICK_TO_ENTER_COMMENT) |
544 end, | 547 -- end, |
545 }) | 548 -- }) |
546 | 549 -- |
547 private.data_obj = data_obj | 550 -- private.data_obj = data_obj |
548 LibStub("LibDBIcon-1.0"):Register(ADDON_NAME, data_obj, private.db.global.config.minimap_icon) | 551 -- LibStub("LibDBIcon-1.0"):Register(ADDON_NAME, data_obj, private.db.global.config.minimap_icon) |
552 | |
553 _G["BINDING_HEADER_WOWDB_PROFILER"] = "WoWDB Profiler" | |
549 end | 554 end |