Page 1 of 1

Stdlib bug in hasBG

Posted: Tue May 10, 2011 7:19 pm
by Paul MR
Hi x, this function will fail as it's trying to get ref and should be bgref
Code: Select allStdlib.hasBG = function(doc) {
  try {
    var bgref = new ActionReference();
    bgref.putIndex(cTID("Lyr "), 0);
    executeActionGet(ref);
    return true;
  } catch (e) {
    return false;
  }
}

Stdlib bug in hasBG

Posted: Wed May 11, 2011 2:20 am
by xbytor
Right, you are. I normally use Stdlib.hasBackground(), the DOM-style version.

I'll make the change and push it out to sourceforge later tonight.

Thanks for the find.

Stdlib bug in hasBG

Posted: Wed May 11, 2011 2:55 am
by xbytor
I dropped in the fix and also made the change to account for the new BridgeTalk.appVersion format for PSCS5.5.