public inbox for [email protected]  
help / color / mirror / Atom feed
From: Aditya Toshniwal <[email protected]>
To: pgadmin-hackers <[email protected]>
Subject: RM#3294 - User need to reset the layout to see the changed preferences parameters
Date: Mon, 11 Jun 2018 18:02:50 +0530
Message-ID: <CAM9w-_=G54p43OBgLB3kMQhQDosW2+7mu7sXtuPSCXxuiRhBhg@mail.gmail.com> (raw)

Hi Hackers,

This is regarding RM3294 which I am working on, where user needs to reset
the layout to see the changed preferences parameters. I am able to
implement it, and have used the following approach:
1) when preference changed, fire a custom event - prefChangedEvent
2) listent to prefChangedEvent wherever preferences should be reflected in
realtime.
3) In the event handler, make the changes as per the module.
4) So whenever the preferences are changed, the event fires, the listener
executes the event handler and changes are done.

Benefit of this approach is no polling. But, there is a problem here.
It is not possible to fire event in another tab/new browser window. For
example, query tool can be open in another tab. And thus, changes are not
reflected there. There are solutions available like updating the
localStorage of the browser but those are not reliable and does not work
properly on different browsers.

Request you to kindly suggest if you any better idea.

Thanks and Regards,
Aditya Toshniwal
Software Engineer | EnterpriseDB Software Solutions | Pune
"Don't Complain about Heat, Plant a tree"


view thread (6+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected]
  Subject: Re: RM#3294 - User need to reset the layout to see the changed preferences parameters
  In-Reply-To: <CAM9w-_=G54p43OBgLB3kMQhQDosW2+7mu7sXtuPSCXxuiRhBhg@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox