On Fri, 8 Jul 2022 18:12:36 GMT, Kevin Rushforth <k...@openjdk.org> wrote:
>> The last time we updated. >> If the number of printers has changed I will always rebuild the printer list >> (set) but if they are the same >> what are the odds a printer was removed and another one added ? >> I figured if 2 minutes has passed since we last checked it is worth it, but >> I am not re-setting this every >> time we called getAllPrinters() else if you kept calling it every 30 seconds >> .. then we'd never get past that check. > > In that case shouldn't the assignment of `lastTime` be moved up two lines, > right below the call to `updatePrinters`? Or am I missing something? I guess I knew what I wanted but didn't have the code to match :-) ------------- PR: https://git.openjdk.org/jfx/pull/817