如何在JavaFX中将其设置为警报窗口标题栏图标?
public static void show(String titleString, String messageString, AlertType status, String iconStr)
{
Alert alert = new Alert(status);
alert.setTitle(titleString);
alert.setHeaderText("");
alert.setContentText(messageString);
alert.showAndWait();
}
感谢。
答案 0 :(得分:1)
尝试data = [{'info': ('orange', 400000, 'apple'), 'photo': None}, {'info': ('grape', 485000, 'watermelon'), 'photo': None}]
new_data = sorted(data, key=lambda x:x.get('info', [0, 0])[1])