Class AsyncBufferedImage

    • Constructor Detail

      • AsyncBufferedImage

        public AsyncBufferedImage​(ClientThread clientThread,
                                  int width,
                                  int height,
                                  int imageType)
    • Method Detail

      • loaded

        public void loaded()
        Call when the image has been loaded
      • onLoaded

        public void onLoaded​(Runnable r)
        Register a function to be ran when the image has been loaded. If the image is already loaded the function will be invoked later on the client thread.
      • addTo

        public void addTo​(JButton c)
        Calls setIcon on c, ensuring it is repainted when this changes
      • addTo

        public void addTo​(JLabel c)
        Calls setIcon on c, ensuring it is repainted when this changes