Show toast on the UI thread.
@param applicationContext the application context.
@param message the message to show.
@param duration the display duration.
11004
public static void showOnUiThread(Context applicationContext, String message, int duration) {
        Handler handler = HandlerUtils.getMainHandler();
        showOnUiThread(applicationContext, message, duration, handler);
    }
217686
def show_message(self, message, timeout=0):
        """"""
        self.main.statusBar().showMessage(message, timeout)
200862
public static void showToast(String message, int duration) {
		showToast(message, duration, null, null, null);
	}
443397
protected void showLightError(String msg) {
    if (getActivity() != null) {
      Toast.makeText(getActivity(), msg, Toast.LENGTH_SHORT).show();
    }
  }
1030880
function panelAction (cb, message = null) {
  if (created && panelLoaded && panelShown) {
    cb()
  } else {
    pendingAction = cb
    message && toast(message)
  }
}
594201
public void sendMessage(String message) {
        EventBuilder eventBuilder = new EventBuilder().withMessage(message)
            .withLevel(Event.Level.INFO);
        sendEvent(eventBuilder);
    }
1275079
private void showCheatsheet(Context context, View view) {

		final int[] screenPos = new int[2];
		final Rect displayFrame = new Rect();
		view.getLocationOnScreen(screenPos);
		view.getWindowVisibleDisplayFrame(displayFrame);

		final int width = view.getWidth();
		final int height = view.getHeight();
		final int midy = screenPos[1] + (height / 2);
		final int screenWidth = context.getResources().getDisplayMetrics().widthPixels;
		Toast cheatSheet = Toast.makeText(context, title, Toast.LENGTH_SHORT);
		if (midy < displayFrame.height()) {
			// Show along the top; follow action buttons
			cheatSheet.setGravity(Gravity.TOP | Gravity.RIGHT, screenWidth - screenPos[0] - (width / 2), height);
		} else {
			// Show along the bottom center
			cheatSheet.setGravity(Gravity.BOTTOM | Gravity.CENTER_HORIZONTAL, 0, height);
		}
		cheatSheet.show();
	}
754831
public static void showOnUiThread(Context applicationContext, int stringResId, int duration) {
        Handler handler = HandlerUtils.getMainHandler();
        showOnUiThread(applicationContext, stringResId, duration, handler);
    }
1329067
def _show_toast(self, title, msg,
                    icon_path, duration):
        
        message_map = {WM_DESTROY: self.on_destroy, }

        # Register the window class.
        self.wc = WNDCLASS()
        self.hinst = self.wc.hInstance = GetModuleHandle(None)
        self.wc.lpszClassName = str("PythonTaskbar")  # must be a string
        self.wc.lpfnWndProc = message_map  # could also specify a wndproc.
        try:
            self.classAtom = RegisterClass(self.wc)
        except:
            pass #not sure of this
        style = WS_OVERLAPPED | WS_SYSMENU
        self.hwnd = CreateWindow(self.classAtom, "Taskbar", style,
                                 0, 0, CW_USEDEFAULT,
                                 CW_USEDEFAULT,
                                 0, 0, self.hinst, None)
        UpdateWindow(self.hwnd)

        # icon
        if icon_path is not None:
            icon_path = path.realpath(icon_path)
        else:
            icon_path =  resource_filename(Requirement.parse("win10toast"), "win10toast/data/python.ico")
        icon_flags = LR_LOADFROMFILE | LR_DEFAULTSIZE
        try:
            hicon = LoadImage(self.hinst, icon_path,
                              IMAGE_ICON, 0, 0, icon_flags)
        except Exception as e:
            logging.error("Some trouble with the icon ({}): {}"
                          .format(icon_path, e))
            hicon = LoadIcon(0, IDI_APPLICATION)

        # Taskbar icon
        flags = NIF_ICON | NIF_MESSAGE | NIF_TIP
        nid = (self.hwnd, 0, flags, WM_USER + 20, hicon, "Tooltip")
        Shell_NotifyIcon(NIM_ADD, nid)
        Shell_NotifyIcon(NIM_MODIFY, (self.hwnd, 0, NIF_INFO,
                                      WM_USER + 20,
                                      hicon, "Balloon Tooltip", msg, 200,
                                      title))
        # take a rest then destroy
        sleep(duration)
        DestroyWindow(self.hwnd)
        UnregisterClass(self.wc.lpszClassName, None)
        return None
517122
protected void configureMessageConverter(ApplicationContext context) {
        if (context.containsBean(MESSAGE_CONVERTER_BEAN_NAME)) {
            HttpMessageConverter messageConverter = context.getBean(MESSAGE_CONVERTER_BEAN_NAME, HttpMessageConverter.class);

            if (messageConverter instanceof DelegatingHttpEntityMessageConverter) {
                ((DelegatingHttpEntityMessageConverter) messageConverter).setBinaryMediaTypes(httpServer.getBinaryMediaTypes());
            }
        }
    }
830216
private void displayMessageAtTheBeginningOfMethod(String methodName, List<GherkinStepCondition> conditions) {
        logger.debug("{} with {} contition(s)", methodName, conditions.size());
        displayConditionsAtTheBeginningOfMethod(conditions);
    }
1061284
public static void showSoftKeyboard(Context context, View view) {
        if (view == null) {
            return;
        }

        final InputMethodManager manager = (InputMethodManager)
                context.getSystemService(Context.INPUT_METHOD_SERVICE);
        view.requestFocus();
        manager.showSoftInput(view, 0);
    }
141857
public static void toast(String message) {

        Toast toast = Toast.makeText(QuickUtils.getContext(), message, Toast.LENGTH_SHORT);
        toast.show();
    }
199201
protected void addMessage(String message)
    {
        messages.add(message);
        messageCount++;
        if (messageCount > messagesQueueMax)
        {
            messages.remove();
            messageCount--;
        }
    }
895998
def show_message(self, message, duration=2500):
        

        self.setText(message)
        self.__duration = duration

        self.__set_position()

        if message:
            self.__fade_in()
        else:
            self.__fade_out()
        return True
241869
public void showLoadingAnimation(String msg) {

        removeLoadingAnimation();
        m_loadingPanel = new FlowPanel();
        m_loadingPanel.addStyleName(I_CmsLayoutBundle.INSTANCE.uploadButton().loadingPanel());
        m_loadingPanel.addStyleName(org.opencms.gwt.client.ui.css.I_CmsLayoutBundle.INSTANCE.generalCss().cornerAll());

        CmsLoadingAnimation animationDiv = new CmsLoadingAnimation();
        animationDiv.addStyleName(I_CmsLayoutBundle.INSTANCE.uploadButton().loadingAnimation());
        m_loadingPanel.add(animationDiv);

        HTML messageDiv = new HTML();
        messageDiv.addStyleName(I_CmsLayoutBundle.INSTANCE.uploadButton().loadingText());
        messageDiv.setHTML(msg);
        m_loadingPanel.add(messageDiv);

        m_container.add(m_loadingPanel);
    }
636001
public void displaySuccess(final String message) {
        notificationMessage.showNotification(SPUIStyleDefinitions.SP_NOTIFICATION_SUCCESS_MESSAGE_STYLE, null, message,
                true);
    }