Thread Tools Display Modes
01-22-10, 02:15 PM   #61
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Just as a clarification at present this is the precursor stage to implementing an infopanel. I usually make a standalone version first and then treat it as an addon and plug it into the infopanel system afterwards. So, once I have it working as a standalone addon with nUI running, hopefully the infopanel side of things will be easier. At present though the infopanel side is horrendously wrong. But then, if the non infopanel version is not working the way it should it could be making the infopanel version worse.

So, basically, at this stage, this addon is not dependant on nUI and so loads before it. However, because nUI plays with the WatchFrame when it loads up by the time I try to play with it, I'm not sure how the changes nUI makes are affecting things. Although, now it seems they are not affecting it as much as I thought. Perhaps just a flaw in the ScrollFrame system or the WatchFrame just doesn't want to stay out of sight rofl.

Anyway, play with it Scott and you can see what I mean. It's hard to put the problem in screenshots.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-22-10, 06:36 PM   #62
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
FWIW -- You can still make your addon dependent on nUI even if you aren't embedding the frame in the info panel... that will cause WoW to load nUI before it loads your addon.

I'm wiped from work today, but if I get a second wind tonight I'll look at it, otherwise, I'll look at it in the morning.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-22-10, 07:36 PM   #63
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
No worries Scott. It's a work in progress. And it's made significant progress since my last look at it last week so rofl, maybe leave it for a week and it will work rofl.

Not sure it will make much difference the way I am doing it as it is. It is not dependant on nUI, so that other users can use it without it. But, if you do have nUI it will use the functions you set up for locking and unlocking etc.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 06:49 AM   #64
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
I'll keep that in mind... I'm having my first cup of coffee here this morning and about to do my dailies on my priest and DK real quick then I'll spend some time on it before I get back to nUI6.

I'll post results in a bit.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 09:24 AM   #65
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
Success -- I got it working. Just e-mailed you back a copy.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 09:27 AM   #66
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Sweet thanks. Will take a look shortly. Would be interesting to see what was causing the headache

Hopefully then I'll be able to have a version that works outside of an infopanel for both nUI users and non users and then the infopanel version

Throw in some options to change width/height lock and unlock etc
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 10:23 AM   #67
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
You should be able to do it all with one addon... just add the stuff to deal with the nUI integration if the ADDON_LOADED gets called for nUI.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 11:09 AM   #68
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Yeah, I'll see what I can do there, usually I have the integration part in a separate file to tidy things up

And it would mess my naming pattern up

If I do it right though, the non integrated one would use the same file as the integrated one except have the second file to handle the integration itself. One file for both addons just copy and paste the file as needed
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 11:52 AM   #69
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
Nah... all you have to do is to add the usual info panel integration functions to the "WatchFrame_Container" frame you've already created and instead of parenting it to the user interface, parent it to the info panel container nUI passes you. When you see nUI in the ADDON_LOADED function then you can add your "info panel" to the list of info panels then. That way you only have one mod to maintain and it and nUI would automatically recognize each other... that's kind of how I always envisioned nUI info panels working in the first place.

If you're stuck on how to do it, let me know and I'd be happy to put it together so you have a template to go by.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 02:00 PM   #70
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Ah, I've been using the same template for all my infopanels and they have quite a bit of code in that looks like it needs to be there for the system to work. Rofl, have I been using excess useless code all this time rofl ?

Edit: Did I say I was good at English rofl. Nonsensical sentence corrected
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818

Last edited by Xrystal : 01-23-10 at 02:21 PM.
 
01-23-10, 02:12 PM   #71
Marthisdil
An Onyxian Warder
AddOn Author - Click to view addons
Join Date: Jan 2005
Posts: 363
Have I mentioned how much i love you guys?!? Can't wait to try it out!

Thanks Scott and Xrystal!
__________________

Marth



 
01-23-10, 02:58 PM   #72
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Hmm, might try your idea out Scott as the normal way I set up the infopanels isn't working this time rofl. The WatchFrame isn't moving with the scrolling frame container rofl.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 03:56 PM   #73
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Woot, thanks Scott. It was a fair bit of code to set it up that way but it makes sense in the long run. Some of our panel plugins like the professions and mageports may be useable outside of nUI this way.

Anyways, tweaked with some variable changes and new variables and now I have a flag for if nUI is active and one for if you want it in an infopanel.

If you flag it up as being placed in the infopanel it will set it all up and throw it in there and it scrolls brilliantly And doesn't move

If you flag it up as non infopanel it will use the larger height options available and be movable.

Next step is to see if I can toggle it inside the game to be an infopanel item or not If that works it may be useful for these plugins like healbot and grid which overflow in 25 man runs which kinda messes us up. Well, until version 6 comes out anyway.

Here's a few screenshots anyway

First is the infopanel option, seconds is a non infopanel one but still in nUI and third is for those that haven't braved the world of nUI but are screaming for a resizable/movable watchframe
Attached Thumbnails
Click image for larger version

Name:	WoWScrnShot_012310_214246.jpg
Views:	565
Size:	251.3 KB
ID:	3888  Click image for larger version

Name:	WoWScrnShot_012310_214610.jpg
Views:	569
Size:	265.8 KB
ID:	3889  Click image for larger version

Name:	WoWScrnShot_012310_214711.jpg
Views:	566
Size:	250.4 KB
ID:	3890  
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 04:01 PM   #74
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
Awesome sauce...

Now... let me throw down the gauntlet to you... something I noticed when I was playing with it. There's that little red button in there you can click on to collapse the watch frame. It would be cool if you could hook that and have it resize the WatchFrame_Container, as well.

Show me how brilliant you are now Ma'am

~smile~
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 04:20 PM   #75
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
ooh, a challenge rofl. Never been good at hacking into existing functions
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 04:38 PM   #76
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
You don't have to hack the existing function... you can just hook it so you know when it's called...

Code:
local function myHookFunction()
    -- do something cool
end

hooksecurefunc( "blizzFunctionName", myHookFunction );
Your function will get called when the function name you specified is called.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
01-23-10, 04:47 PM   #77
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
ah, never used that function before.

Hmm, must be doing something wrong. It doesn't seem to be using my function at all.

Code:
local function WatchFrame_CollapseExpand(self)
	print("In my CollapseExpand Function");
	if ( WatchFrame.collapsed ) then
		WatchFrame_Expand(WatchFrame);
		PlaySound("igMiniMapOpen");	
		if ( WatchFrameScrollFrame and not tFlags.nUI_InfoPanel ) then		
			WatchFrameScrollFrame:SetHeight( WatchFrame:GetHeight() );
		end
	else
		WatchFrame_Collapse(WatchFrame);
		PlaySound("igMiniMapClose");
		if ( WatchFrameScrollFrame and not tFlags.nUI_InfoPanel ) then		
			WatchFrameScrollFrame:SetHeight( tValues.height );
		end
	end
end
hooksecurefunc( "WatchFrame_CollapseExpandButton_OnClick", WatchFrame_CollapseExpand );

Edit: Ah, gonna have to use HookScript somehow as it will never run my function as it will always run theirs due to the script set up.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818

Last edited by Xrystal : 01-23-10 at 04:54 PM.
 
01-23-10, 05:08 PM   #78
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Rofl, I broke it

Code:
local ceb = _G["WatchFrameCollapseExpandButton"];
ceb:HookScript("OnClick",WatchFrame_CollapseExpand);
It seems to work, once. It resizes the window to a size I ask but then doesn't do the rest of the changes that the watchframe did before I hooked that script. Even though the script only called the function I have replaced.
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818
 
01-23-10, 05:10 PM   #79
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
This seems to work (though I don't have the "tFlags" part of your code)

Code:
local function myWatchFrame_Collapse(self)
    print("In my Collapse Function");
    if ( WatchFrameScrollFrame and not tFlags.nUI_InfoPanel ) then        
        WatchFrameScrollFrame:SetHeight( WatchFrame:GetHeight() );
    end
end

local function myWatchFrame_Expand(self)
    print("In my Expand Function");
    if ( WatchFrameScrollFrame and not tFlags.nUI_InfoPanel ) then        
        WatchFrameScrollFrame:SetHeight( tValues.height );
    end
end

hooksecurefunc( "WatchFrame_Collapse", myWatchFrame_Collapse );
hooksecurefunc( "WatchFrame_Expand", myWatchFrame_Expand );
EDIT: Note... you don't have to make the call to WatchFrame_Collapse() or WatchFrame_Expand() because your function doesn't get called until AFTER the "hooked" function has been executed... it does not replace the function, it just causes your function to be called after the hooked function is executed.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/

Last edited by spiel2001 : 01-23-10 at 05:12 PM.
 
01-23-10, 05:11 PM   #80
Xrystal
nUI Maintainer
 
Xrystal's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 5,934
Yeah, re-read what hookscript does and realised that I was duplicating their code and messing things up. So now trying to figure out the best way to handle the scrolling as it lets you scroll cos the scroll size is still big rofl.

Edit1: Ah. WatchFrame seems to be set to 139.xxx in height, timers perhaps. And the scrolling scrolls for that much. I guess that can be enough.

Edit2: Oh, I see what you did there rofl. Yours is better
__________________


Characters:
Gwynedda - 70 - Demon Warlock
Galaviel - 65 - Resto Druid
Gamaliel - 61 - Disc Priest
Gwynytha - 60 - Survival Hunter
Lienae - 60 - Resto Shaman
Plus several others below level 60

Info Panel IDs : http://www.wowinterface.com/forums/s...818#post136818

Last edited by Xrystal : 01-23-10 at 05:18 PM.
 
 

WoWInterface » Featured Projects » nUI, MozzFullWorldMap and PartySpotter » Customization » nUI: Developer Chat » Quest Tracker Info Panel


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off