From 29ebd3838a28af99f6e8ffe2ae06c4306be440a9 Mon Sep 17 00:00:00 2001 From: benfry Date: Tue, 30 Jul 2002 23:18:25 +0000 Subject: [PATCH] fixed button background on editor status for os9, tweaked for osx --- processing/app/PdeEditorStatus.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/processing/app/PdeEditorStatus.java b/processing/app/PdeEditorStatus.java index bb9e5edbb..849baf0a8 100644 --- a/processing/app/PdeEditorStatus.java +++ b/processing/app/PdeEditorStatus.java @@ -172,7 +172,9 @@ public class PdeEditorStatus extends Panel public void update() { Graphics g = this.getGraphics(); - setBackground(bgcolor[mode]); + try { + setBackground(bgcolor[mode]); + } catch (NullPointerException e) { } // if not ready yet if (g != null) paint(g); } @@ -189,15 +191,13 @@ public class PdeEditorStatus extends Panel okButton = new Button(PROMPT_OK); // !@#(* aqua ui #($*(( that turtle-neck wearing #(** (#$@)( - /* - if ((PdeBase.platform == PdeBase.MACOSX) || - (PdeBase.platform == PdeBase.MACOS9)) { + // os9 seems to work if bg of component is set, but x still a bastard + if (PdeBase.platform == PdeBase.MACOSX) { yesButton.setBackground(bgcolor[PROMPT]); noButton.setBackground(bgcolor[PROMPT]); cancelButton.setBackground(bgcolor[PROMPT]); okButton.setBackground(bgcolor[PROMPT]); } - */ setLayout(null); yesButton.addActionListener(this);