1775 if (useSystemAAFontSettings()) {
1776 Toolkit tk = Toolkit.getDefaultToolkit();
1777 if (tk instanceof SunToolkit) {
1778 Object map = ((SunToolkit)tk).getDesktopAAHints();
1779 return (RenderingHints)map;
1780 } else { /* Headless Toolkit */
1781 return null;
1782 }
1783 } else if (desktopFontHints != null) {
1784 /* cloning not necessary as the return value is cloned later, but
1785 * its harmless.
1786 */
1787 return (RenderingHints)(desktopFontHints.clone());
1788 } else {
1789 return null;
1790 }
1791 }
1792
1793
1794 public abstract boolean isDesktopSupported();
1795
1796 /*
1797 * consumeNextKeyTyped() method is not currently used,
1798 * however Swing could use it in the future.
1799 */
1800 public static synchronized void consumeNextKeyTyped(KeyEvent keyEvent) {
1801 try {
1802 AWTAccessor.getDefaultKeyboardFocusManagerAccessor().consumeNextKeyTyped(
1803 (DefaultKeyboardFocusManager)KeyboardFocusManager.
1804 getCurrentKeyboardFocusManager(),
1805 keyEvent);
1806 } catch (ClassCastException cce) {
1807 cce.printStackTrace();
1808 }
1809 }
1810
1811 protected static void dumpPeers(final PlatformLogger aLog) {
1812 AWTAutoShutdown.getInstance().dumpPeers(aLog);
1813 }
1814
|
1775 if (useSystemAAFontSettings()) {
1776 Toolkit tk = Toolkit.getDefaultToolkit();
1777 if (tk instanceof SunToolkit) {
1778 Object map = ((SunToolkit)tk).getDesktopAAHints();
1779 return (RenderingHints)map;
1780 } else { /* Headless Toolkit */
1781 return null;
1782 }
1783 } else if (desktopFontHints != null) {
1784 /* cloning not necessary as the return value is cloned later, but
1785 * its harmless.
1786 */
1787 return (RenderingHints)(desktopFontHints.clone());
1788 } else {
1789 return null;
1790 }
1791 }
1792
1793
1794 public abstract boolean isDesktopSupported();
1795 public abstract boolean isTaskbarSupported();
1796
1797 /*
1798 * consumeNextKeyTyped() method is not currently used,
1799 * however Swing could use it in the future.
1800 */
1801 public static synchronized void consumeNextKeyTyped(KeyEvent keyEvent) {
1802 try {
1803 AWTAccessor.getDefaultKeyboardFocusManagerAccessor().consumeNextKeyTyped(
1804 (DefaultKeyboardFocusManager)KeyboardFocusManager.
1805 getCurrentKeyboardFocusManager(),
1806 keyEvent);
1807 } catch (ClassCastException cce) {
1808 cce.printStackTrace();
1809 }
1810 }
1811
1812 protected static void dumpPeers(final PlatformLogger aLog) {
1813 AWTAutoShutdown.getInstance().dumpPeers(aLog);
1814 }
1815
|