| |
| |
| |
|
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Comments:
<0> well that's easy <0> why didn't he just say so <1> rob__, how much memory _do_ you have? O.o <2> pstickne: 3.5gb <3> Jan-: Lol. :-P <2> 6 x 512mb, 2 x 256mb <0> When do I get to put my "fairly clever coder" hat on? <2> :) <3> Lol <1> rob__, :(( <3> You can have mine. :-P <2> pstickne: why the sad face? <1> rob__, it's more then double what I have :x <0> I can't change what "this" refers to, can I. <1> rob__, how'd you get "stuck" with two smaller sticks?
<3> Jan-: 'fraid not. :-) <2> pstickne: hah <0> Twey_: Okay. The problem I have is that my inner function was originally designed to work on "this" a lot, and making it a returned function as part of a closure messes up what "this" now refers to. <2> right now i have too many windows to count open including windows xp running in virtualpc (emulating the cpu) <0> So I have a big, ugly, global variable called wwsCurrentWin <0> There has to be a better way <4> hey all - i use the getElementByID function - and i put new html in a div - and theres an img in the element but in IE the image never shows up <0> I guess I could p*** an object reference <3> Jan-: Uuurgh. <3> Jan-: You have a big ugly global namespace. <3> Jan-: Then put everything else inside it. <0> I have lots of big, ugly globality, yes. <0> Part of "preparing this code for human consumption" is to reduce its globality a bit. <0> A lot. <3> Jan-: As for changing what "this" refers to <2> pstickne: http://img79.imageshack.us/img79/8647/exposefg3.jpg is the power of ram :) <3> Jan-: You can use Function.apply() and Object.call() <0> I could do what now? <3> Jan-: Say you had a function called a <0> Mmhmm <3> Jan-: If you a.apply(b) it will call a, and all references to "this" inside a will refer to b <3> Jan-: b.call(a) has the same effect <0> I need this to refer to a dom object not a function <3> Jan-: It'll work with any object <0> That causes an intrinsic problem <3> Jan-: Hm? <0> I just went to a ton of trouble to ensure that a() gets a load of variables in its scope <0> if I have to call it explicitly as myDomObject.call(a), it will be outside that scope again <0> I'd have to do myDomObject.call(thisFuncReturnsAFunc()) <0> if I can <3> Jan-: That should work <0> this really is going to be a glittering example of advanced JS coding techniques <0> Twey_: How d'you know my code is so.... global? <3> Jan-: You said so? :-P <0> Oh, OK. <3> Jan-: And I've seen it. ;-) <0> Ah. <1> rob__, you are insane <0> I guess when I make all this a bit more modular, I should wrap all the functions for one module in a large object or something. <1> rob__, now, send me your mac :x <3> Jan-: That's called a namespace. :-P <2> pstickne: i only paid for it <0> A what now? <3> Jan-: That's what I was talking about earlier <1> rob__, I'm actually drooling over the new T60 thinkpads... <3> Jan-: A namespace is a ruddy big object, usually global, in which you put everything. <1> rob__, but there is no need for me to upgrade so *shrug* <2> pstickne: dual 1.8 G5, 3.5gb ram.. then I replaced the hard disks and now have a RAID0 setup :) i'm content <3> Jan-: Well -- not global as such. <0> Well I have four modules right now. <3> Jan-: It tends to get put inside window. <1> rob__, add another HD and get RAID5. <0> Core, Clock, Xbrowser and Log <0> I guess they should have one each <2> pstickne: only 2 HDD bays <3> Jan-: What happened to Clock? I don't see it any more. <1> rob__, did it come with the monitor? (It's the Cinema, right?) <0> I turned it off, it was causing problems with the new closure establishment of wwsSetScrollbars() <2> pstickne: tower only <0> at this stage, changes to Core that cause problems in other modules will be considered bugs in the external modules.
<3> Jan-: Ah right <2> pstickne: it's hooked up to a 19" acer until I get my 24" sorted <0> Clock does some funky stuff with resizing when it inits. I'll debug it later. <3> Jan-: Lol. A Microsoftian approach? :-P <1> rob__, I was going to say to had a killer of a deal if it came with the monitor -- bought my brother a 20" last christmas. damn, they're pricey. <0> Twey_: No, Clock is not release code yet :) <0> Hang on. <3> Jan-: Haha, point :-P <0> If I do this: <0> wwsCurrentScrollWin.setScrollBars=wwsScrollCache(); <2> pstickne: hell yes they are. i wouldn't buy an apple monitor, i'd go for a dell or LG <0> then when setScrollbars() is called, "this" will indeed refer to wwsCurrentScrollWin <0> ....won't it? <3> Jan-: Yes <2> pstickne: right now i dont have desk space for a bigger monitor than this though <1> rob__, they use the same lcd core as some of the dell's ... but I dislike dell brand. also, doesn't lg use its own? <2> pstickne: some of the LGs are nice. especially the 20" they have here, it's a fantastic panel <1> rob__, that is why iMacs are such a steal these days -- the 20" screen is so gorgeous ;) <0> hey guys, I have a Dell 2405FPW :) <2> pstickne: yeah - the screen would set you back 1/3 the cost easily <1> Jan-, nice <0> *snicker* <2> pstickne: they max out at 2gb ram though so are no good <1> rob__, I know ;X <0> And much good may it do me! <3> Lol <1> rob__, depends on application. but 512mb is definately the lower-limit. <3> :-( <2> pstickne: I mainly do print design. I wouldn't use less than 2gb <5> Hey <1> rob__, I do ... no design. 1.5GB is more then plenty. <5> I have an unordered list and want to add one item to that <5> how do I do that? <3> Mine's a Compaq P920... got it for off a friend ^_^ <5> preferably in a specific place <1> dazjorz, you mean you have an array? <2> pstickne: I like to have photoshop, illustrator and indesign open. Those three can easily use 1gb each if you're not careful <3> dazjorz: e.appendChild(document.createElement("li")); <1> dazjorz, if you mean hash/object then, just as you said "unordered" <5> pstickne: no, err, when the user clicks a link, i want to add one item to the list, in a specific place <0> Is it good practice to do a.call(b) just to be able to use "this" inside b(), and to save ugly globals? <5> Twey_: Yeah, thats append, comes after the last one, i need it in the middle or something <1> Twey_, might be more on-track then ;) <3> dazjorz: It makes much more sense to have it already there, but invisible. <5> Twey_: Yeah, better idea <5> Twey_: How do I make it invisible? <3> dazjorz: Set .style.display = "none" <5> Twey_: CSS or javascript? =/ <3> dazjorz: Javascript <5> Allright <3> dazjorz: If you're going to unhide something with Javascript, it should be hidden in Javascript in the first place <5> Twey_: Okay <3> dazjorz: Otherwise non-JS users won't be able to see it. <5> Twey_: Yeah. <5> Twey_: Can I just add that to the tag? <3> dazjorz: No, you'll have to do it onload. <5> Twey_: Okay. <0> What am I doing wrong: <0> wwsCurrentScrollWin.setScrollBars=wwsScrollCache.apply(wwsCurrentScrollWin); <3> Jan-: Er. <0> Go on <0> Laugh <0> See how I care! <4> hey all - i use a little bit of javascript to change the content of a div and put a new img in it - but the img doesn't show up in IE6 -- do i need to do something to preload it <0> wwsScrollCache() being a function, and wwsCurrentScrollWin being a pointer to a DOM object. <3> jseval: var d = {'c': 'Hi' }; var a = function() { return function() { return this.c; } }; var b = a.apply(d); <6> Twey_: Return: undefined <3> ... <0> At the mo, I have to use that DOM reference tons inside the function. <0> I'd like to avoid it. <3> jseval: var d = {'c': 'Hi' }; var a = function() { return function() { return this.c; } }; return a.apply(d);
Return to
#javascript or Go to some related
logs:
suse +R200DALSetControllerConfigForRemap] parseJSON() carriage return gmail configuration sendmail.mc db2omf gentoo #fedora update eix illegal instruction #php #perl #linux #debian
|
|