billy2

  • Trying to earn brownie points for a lads trip to the Red Sea. Minus 1 already - just for asking!!
  • Posts: 350
Re: PM popup
« Reply #15, on October 10th, 2011, 03:26 PM »
Quote from Arantor on October 10th, 2011, 03:16 PM
Well, I'll note it wasn't entirely original but it took a different direction minutes after I posted. It's almost like I tried to do something new, different and interesting ;) :lol:
Well, it is your motto after all is said and done....... Innovate not Imitate  :lol:

<br /><br />cough, cough.

DirtRider

  • All truth, in the long run, is only common sense clarified.
  • Posts: 303
Re: PM popup
« Reply #16, on October 11th, 2011, 02:55 PM »
Quote from Arantor on October 10th, 2011, 01:29 PM
The lower right window is, I suspect, where I'll end up doing it, just doing some other stuff first.
I like this way of doing it really look much more professional.
“Any code of your own that you haven’t looked at for six or more months might as well have been written by someone else.”
(Eagleson’s Law)

Today's Logo

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: PM popup
« Reply #17, on August 23rd, 2013, 10:50 PM »
Hmmm. When I originally thought about this, I certainly hadn't thought about the revamp I've since carried out which pretty much nukes this idea.

I haven't yet removed the popup, but I might as well now - it's pretty clear at the top of the page that you have something to deal with... anyone want me to leave the PM 'you have new messages, would you like to read them in a new window?' message?
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

Nao

  • Dadman with a boy
  • Posts: 16,078
Re: PM popup
« Reply #18, on August 24th, 2013, 12:01 AM »
Yes, I don't see any problem in removing it; but that's mainly because I always found this to be overkill...
Amusingly, I had the same idea when studying the patch file; but I figured you would disagree with me. I was wrong, I guess ;)

BTW, while on the subject...
I rewrote the JS PM notif code to save about 80 gzipped bytes; it's not MUCH indeed, but it's better than nothing.
However, my rewrite consists in making a 'generic' object to handle any kind of notification popup, but I have two problems:
- I hardly see any reason for a plugin to add another type of notification...?! They would probably add themselves to the generic notifications, no..?
- I'm having trouble with the auto_update, ah ah... Because getting both notification numbers from the same request implies calling handlers from within a higher scope, so it's... Quite a bit fucked up.

I'm probably gonna give up on this, but I have to admit, I'm not thrilled with having so much repeated code in script.js, although it DOES compress very well, compared to the amount of code, so...

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: PM popup
« Reply #19, on August 24th, 2013, 12:08 AM »
Here's the thing, there aren't two kinds of 'notifications'. There are two kinds of popups, and I've deliberately held off making a third because of this.
Quote
- I hardly see any reason for a plugin to add another type of notification...?! They would probably add themselves to the generic notifications, no..?
Yup. Though I still want to use the same general mechanism for adding a profile menu next to the notifications menu where we can put the avatar and profile menu navigation.
Quote
- I'm having trouble with the auto_update, ah ah... Because getting both notification numbers from the same request implies calling handlers from within a higher scope, so it's... Quite a bit fucked up.
I deliberately went down that road to minimise bandwidth use and server hit; we already do a regular poll, getting one number, and the auto update function isn't - as far as I can see - bound to any particular scope... and in the same request I'm just outputting something we already had loaded. It just seemed logical to me to do that.

The third popup I want to add, fortunately doesn't have any auto updating, it's just a panel that would be loaded via AJAX when clicked on.

But that would make a third copy of the code, different again :(