javafx.scene.web.WebErrorEvent#javafx.stage.Screen源码实例Demo

下面列出了javafx.scene.web.WebErrorEvent#javafx.stage.Screen 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。

源代码1 项目: HealthPlus   文件: ReceptionistController.java
@FXML
public void showAppointmentSuccessIndicator(String patientId, String consult, String appDate, String appId)
{
    Stage stage= new Stage();
    AppointmentSuccessController success = new AppointmentSuccessController();
    
    success.fillAppointmentData(patientId,consult,appDate,appId);
    
    Scene scene = new Scene(success);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();
}
 
源代码2 项目: HealthPlus   文件: PharmacistController.java
@FXML private void addNewDrug()
{
    
    Stage stage= new Stage();
    AddNewDrugController addDrug = new AddNewDrugController(pharmacist,this);
    addDrug.loadGenericNames();
    Scene scene = new Scene(addDrug);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();

}
 
源代码3 项目: HealthPlus   文件: AdminController.java
@FXML
private void viewOnlineAccounts()
{
    Stage stage = new Stage();
    UserAccountController userAccounts = new UserAccountController("",admin);
    
    ArrayList<ArrayList<String>> data = admin.getOnlineInfo();
    userAccounts.fillUserDetail(data);
    
    Scene scene = new Scene(userAccounts);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码4 项目: Maus   文件: NotificationView.java
public static void openNotification(ClientObject client) {
    Stage stage = new Stage();
    stage.setWidth(300);
    stage.setHeight(125);
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    NotificationView notificationView = new NotificationView();
    stage.setScene(new Scene(notificationView.getNotificationView(), 300, 125));
    stage.setResizable(false);
    stage.setAlwaysOnTop(true);
    stage.setX(primaryScreenBounds.getMinX() + primaryScreenBounds.getWidth() - 300);
    stage.setY(primaryScreenBounds.getMinY() + primaryScreenBounds.getHeight() - 125);
    stage.initStyle(StageStyle.UNDECORATED);
    notificationView.getNotificationText().setWrapText(true);
    notificationView.getNotificationText().setAlignment(Pos.CENTER);
    notificationView.getNotificationText().setPadding(new Insets(0, 5, 0, 20));
    notificationView.getNotificationText().setText("New Connection: " + client.getIP() + " (" + client.getNickName() + ")");
    stage.show();
    PauseTransition delay = new PauseTransition(Duration.seconds(5));
    delay.setOnFinished(event -> stage.close());
    delay.play();
}
 
源代码5 项目: oim-fx   文件: HideTaskBar.java
@Override
public void start(final Stage stage) throws Exception {
	stage.initStyle(StageStyle.UTILITY);
	stage.setScene(new Scene(new Group(), 100, 100));
	stage.setX(0);
	stage.setY(Screen.getPrimary().getBounds().getHeight() + 100);
	stage.show();

	Stage app = new Stage();
	app.setScene(new Scene(new Group(), 300, 200));
	app.setTitle("JavaFX隐藏任务栏");
	app.initOwner(stage);
	app.initModality(Modality.APPLICATION_MODAL);
	app.setOnCloseRequest(new EventHandler<WindowEvent>() {
		@Override
		public void handle(WindowEvent event) {
			event.consume();
			stage.close();
		}
	});

	app.show();
}
 
源代码6 项目: HealthPlus   文件: AdminController.java
@FXML
private void viewLabAccounts()
{
    Stage stage = new Stage();
    UserAccountController userAccounts = new UserAccountController("lab_assistant",admin);
    
    ArrayList<ArrayList<String>> data = admin.getUserInfo("lab_assistant");
    userAccounts.fillUserDetail(data);
    
    Scene scene = new Scene(userAccounts);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码7 项目: Quelea   文件: GraphicsDeviceWatcher.java
/**
 * Create a new device watcher. Internal use only (singleton.)
 */
private GraphicsDeviceWatcher() {
    //lastDeviceCount = GraphicsEnvironment.getLocalGraphicsEnvironment().getScreenDevices().length;
    lastDeviceCount = javafx.stage.Screen.getScreens().size();
    listeners = new ArrayList<>();
    poller = Executors.newScheduledThreadPool(1);
    poller.scheduleAtFixedRate(() -> {
        //GraphicsDevice[] devices = GraphicsEnvironment.getLocalGraphicsEnvironment().getScreenDevices();
        ObservableList<Screen> monitors = Screen.getScreens();
        int thisDeviceCount = monitors.size();  // devices.length;
        if(thisDeviceCount != lastDeviceCount) {
            for(GraphicsDeviceListener listener : listeners) {
                LOGGER.log(Level.INFO, "Number of devices changed, was {0} now {1}", new Object[]{lastDeviceCount, thisDeviceCount});
                if (thisDeviceCount > lastDeviceCount && QueleaProperties.get().getUseAutoExtend()) {
                    QueleaProperties.get().setProjectorScreen(thisDeviceCount - 1);
                }
                lastDeviceCount = thisDeviceCount;
                listener.devicesChanged(monitors);
            }
        }
    }, 0, 3, TimeUnit.SECONDS);
}
 
源代码8 项目: HealthPlus   文件: AddNewDrugController.java
public void showSuccessIndicator()
{
    Stage stage= new Stage();
    SuccessIndicatorController success = new SuccessIndicatorController();
    Scene scene = new Scene(success);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();
}
 
源代码9 项目: DevToolBox   文件: UndecoratorController.java
/**
 * Based on mouse position returns dock side
 *
 * @param mouseEvent
 * @return DOCK_LEFT,DOCK_RIGHT,DOCK_TOP
 */
int getDockSide(MouseEvent mouseEvent) {
    double minX = Double.POSITIVE_INFINITY;
    double minY = Double.POSITIVE_INFINITY;
    double maxX = 0;
    double maxY = 0;
    // Get "big" screen bounds
    ObservableList<Screen> screens = Screen.getScreens();
    for (Screen screen : screens) {
        Rectangle2D visualBounds = screen.getVisualBounds();
        minX = Math.min(minX, visualBounds.getMinX());
        minY = Math.min(minY, visualBounds.getMinY());
        maxX = Math.max(maxX, visualBounds.getMaxX());
        maxY = Math.max(maxY, visualBounds.getMaxY());
    }
    // Dock Left
    if (mouseEvent.getScreenX() == minX) {
        return DOCK_LEFT;
    } else if (mouseEvent.getScreenX() >= maxX - 1) { // MaxX returns the width? Not width -1 ?!
        return DOCK_RIGHT;
    } else if (mouseEvent.getScreenY() <= minY) {   // Mac menu bar
        return DOCK_TOP;
    }
    return 0;
}
 
源代码10 项目: proxyee-down   文件: HttpDownApplication.java
@Override
  public void start(Stage stage) throws Exception {
    initHandle();
    this.stage = stage;
    Platform.setImplicitExit(false);
    SwingUtilities.invokeLater(this::addTray);
    stage.setTitle("proxyee-down-" + version);
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.getIcons().add(new Image(
        Thread.currentThread().getContextClassLoader().getResourceAsStream("favicon.png")));
    stage.setOnCloseRequest(event -> {
      event.consume();
      close();
    });
    beforeOpen();
//    open();
    afterOpen();
  }
 
源代码11 项目: logbook-kai   文件: WindowController.java
/**
 * ウインドウの位置とサイズを設定します。
 * @param location ウインドウの位置とサイズ
 */
public void setWindowLocation(WindowLocation location) {
    if (location != null) {
        boolean intersect = Screen.getScreens()
                .stream()
                .map(Screen::getVisualBounds)
                .anyMatch(r -> r.intersects(
                        location.getX(), location.getY(), location.getWidth(), location.getHeight()));

        if (intersect) {
            this.window.setX(location.getX());
            this.window.setY(location.getY());
            this.window.setWidth(location.getWidth());
            this.window.setHeight(location.getHeight());
        }
    }
}
 
源代码12 项目: HealthPlus   文件: AdminController.java
@FXML
private void showSettings() throws IOException
{
    Stage stage = new Stage();
    SettingsController settings = new SettingsController(admin,this);
    settings.loadConfigFile();
    
    Scene scene = new Scene(settings);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码13 项目: marathonv5   文件: DisplayWindow.java
public ControllerStage(DisplayWindow stage) {
    this.displayWindow = stage;
    setTitle("Marathon Control Center");
    getIcons().add(FXUIUtils.getImageURL("logo16"));
    getIcons().add(FXUIUtils.getImageURL("logo32"));
    initComponents();
    Scene scene = new Scene(content);
    content.getStyleClass().add(StyleClassHelper.BACKGROUND);
    setScene(scene);
    setAlwaysOnTop(true);
    setOnShown((e) -> {
        Rectangle2D screenBounds = Screen.getPrimary().getVisualBounds();
        setX(screenBounds.getWidth() - getWidth());
        setY(0);
    });
    sizeToScene();
    setResizable(false);
    setOnCloseRequest(e -> displayWindow.onStop());
}
 
源代码14 项目: proxyee-down   文件: DownApplication.java
private void initWindow() {
  stage.setTitle("Proxyee Down");
  Rectangle2D bounds = Screen.getPrimary().getVisualBounds();
  int width = 1024;
  int height = 576;
  stage.setX((bounds.getWidth() - width) / 2);
  stage.setY((bounds.getHeight() - height) / 2);
  stage.setMinWidth(width);
  stage.setMinHeight(height);
  stage.getIcons().add(new javafx.scene.image.Image(Thread.currentThread().getContextClassLoader().getResourceAsStream(ICON_PATH)));
  stage.setResizable(true);
  //关闭窗口监听
  stage.setOnCloseRequest(event -> {
    event.consume();
    stage.hide();
  });
}
 
源代码15 项目: DeskChan   文件: OverlayStage.java
public static Rectangle2D getDesktopSize() {
	Rectangle2D rect = Screen.getPrimary().getBounds();
	double minX = rect.getMinX(), minY = rect.getMinY();
	double maxX = rect.getMaxX(), maxY = rect.getMaxY();
	for (Screen screen : Screen.getScreens()) {
		Rectangle2D screenRect = screen.getBounds();
		if (minX > screenRect.getMinX()) {
			minX = screenRect.getMinX();
		}
		if (minY > screenRect.getMinY()) {
			minY = screenRect.getMinY();
		}
		if (maxX < screenRect.getMaxX()) {
			maxX = screenRect.getMaxX();
		}
		if (maxY < screenRect.getMaxY()) {
			maxY = screenRect.getMaxY();
		}
	}
	return new Rectangle2D(minX, minY, maxX - minX, maxY - minY);
}
 
源代码16 项目: HealthPlus   文件: AdminController.java
@FXML
private void viewCashierAccounts()
{
    Stage stage = new Stage();
    UserAccountController userAccounts = new UserAccountController("cashier",admin);
    
    ArrayList<ArrayList<String>> data = admin.getUserInfo("cashier");
    System.out.println(data);
    userAccounts.fillUserDetail(data);
    
    Scene scene = new Scene(userAccounts);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码17 项目: Hostel-Management-System   文件: HostelProject.java
@Override
public void start(Stage stage) throws SQLException, IOException
{
    Parent root = FXMLLoader.load(getClass().getResource("MainScene.fxml"));
    scene = new Scene(root);
    Screen screen = Screen.getPrimary();
    Rectangle2D bounds = screen.getVisualBounds();
    Image ico=new Image("file:///D:/Study/Java/HostelProjecttest/src/hostelproject/media/net.png");
    stage.setTitle("Banda Singh Bahadur Boys Hostel");
    stage.getIcons().add(ico);
    stage.setX(bounds.getMinX());
    stage.setY(bounds.getMinY());
    stage.setWidth(bounds.getWidth());
    stage.setHeight(bounds.getHeight());
    stage.setScene(scene);
    stage.show();
}
 
源代码18 项目: HealthPlus   文件: AdminController.java
@FXML
private void viewDoctorAccounts()
{
    Stage stage = new Stage();
    UserAccountController userAccounts = new UserAccountController("doctor",admin);
    
    ArrayList<ArrayList<String>> data = admin.getUserInfo("doctor");
    userAccounts.fillUserDetail(data);
    
    
    Scene scene = new Scene(userAccounts);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码19 项目: HealthPlus   文件: DoctorController.java
@FXML
public void showSuccessIndicator()
{
    Stage stage= new Stage();
    SuccessIndicatorController success = new SuccessIndicatorController();
    Scene scene = new Scene(success);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();
}
 
源代码20 项目: HealthPlus   文件: DoctorController.java
@FXML private void addTimeSlot()
{
    Stage stage= new Stage();
    NewDoctorTimeSlotController addslot = new NewDoctorTimeSlotController(doc,this);
    Scene scene = new Scene(addslot);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();        
    
    
}
 
源代码21 项目: HealthPlus   文件: ReceptionistController.java
@FXML private void showAppointments()
{
    Stage stage= new Stage();
    AllAppointmentsController app = new AllAppointmentsController(receptionist);
    app.load();
    Scene scene = new Scene(app);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();

}
 
源代码22 项目: HealthPlus   文件: ReceptionistController.java
@FXML
public void showSuccessIndicator()
{
    Stage stage= new Stage();
    SuccessIndicatorController success = new SuccessIndicatorController();
    Scene scene = new Scene(success);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();
}
 
源代码23 项目: HealthPlus   文件: CashierController.java
@FXML
public void showRefundTable()
{
    Stage stage= new Stage();
    RefundController refundTable = new RefundController(this);
  
    refundTable.fillRefundTable();
    
    Scene scene = new Scene(refundTable);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();

}
 
源代码24 项目: mars-sim   文件: QNotification.java
private double getY() {
	double h1 = Screen.getPrimary().getBounds().getWidth();
	double h2 = 0;
	if (Screen.getScreens().size() == 2) {
   		h2 = Screen.getScreens().get(1).getBounds().getWidth();
	}

	// check if mainScene is on primary or secondary and set h0
	double m = getMonitor(h2);
	double h0 = 0;

	if (m == 1)
		h0 = h1;
	else
		h0 = h2;

 //System.out.println("height is " + h0);

    if (null == stageRef) return calcY( 0.0, h0 );

    return calcY(stageRef.getY(), stageRef.getHeight());
}
 
源代码25 项目: HealthPlus   文件: LoginController.java
public void loadDoctor(String username)
{
    Stage stage = new Stage();
    DoctorController doctor = new DoctorController(username);
    
    doctor.fillAreaChart();
    doctor.setAppointments();
    doctor.loadProfileData(); 
    doctor.MakeAvailabilityTable();
    doctor.loadDrugList();
    doctor.loadTestList();
    doctor.setPaceholders();
    doctor.addFocusListener();
    doctor.loadNameList();
    
    stage.setScene(new Scene(doctor));
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.initStyle(StageStyle.UNDECORATED);
    stage.show();
}
 
源代码26 项目: HealthPlus   文件: LoginController.java
public void loadPharmacist(String username)
{
    Stage stage = new Stage();
    PharmacistController pharmacist = new PharmacistController(username);
    
    pharmacist.loadProfileData(); 
    pharmacist.makeStockTable();
    pharmacist.fillBarChart();
    pharmacist.fillPieChart();
    pharmacist.setPaceholders();
    pharmacist.loadNameList();
    pharmacist.addFocusListener();
    
    stage.setScene(new Scene(pharmacist));
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.initStyle(StageStyle.UNDECORATED);
    stage.show();
}
 
源代码27 项目: HealthPlus   文件: LoginController.java
public void loadReceptionist(String username)
{
    Stage stage = new Stage();
    ReceptionistController receptionist = new ReceptionistController(username);
    
    receptionist.loadProfileData(); 
    receptionist.makeSummaryTable();
    receptionist.fillLineChart();
    receptionist.fillCurrentDoctors();
    //receptionist.fillConsultationAreas();
    receptionist.setPaceholders();
    stage.setScene(new Scene(receptionist));
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    stage.initStyle(StageStyle.UNDECORATED);
    stage.show();
}
 
源代码28 项目: HealthPlus   文件: AdminController.java
@FXML
private void viewReceptionistAccounts()
{
    Stage stage = new Stage();
    UserAccountController userAccounts = new UserAccountController("receptionist",admin);
    
    ArrayList<ArrayList<String>> data = admin.getUserInfo("receptionist");
    userAccounts.fillUserDetail(data);
    
    Scene scene = new Scene(userAccounts);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show(); 
}
 
源代码29 项目: HealthPlus   文件: AllMessagesController.java
@FXML private void showMessage()
{
    AllMessages message = (AllMessages)messagesTable.getSelectionModel().getSelectedItem();
    //System.out.println(message.getMessage());
    
    Stage stage= new Stage();
    ReadMessageController newMessage = new ReadMessageController(message,newSysUser);
    newMessage.fillMessage();
    Scene scene = new Scene(newMessage);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();   
    
}
 
源代码30 项目: HealthPlus   文件: NewMessageController.java
public void showSuccessIndicator()
{
    Stage stage= new Stage();
    SuccessIndicatorController success = new SuccessIndicatorController();
    Scene scene = new Scene(success);
    stage.setScene(scene);
    
    Rectangle2D primaryScreenBounds = Screen.getPrimary().getVisualBounds();
    //set Stage boundaries to visible bounds of the main screen
    stage.setX(primaryScreenBounds.getMinX());
    stage.setY(primaryScreenBounds.getMinY());
    stage.setWidth(primaryScreenBounds.getWidth());
    stage.setHeight(primaryScreenBounds.getHeight());
    
    stage.initStyle(StageStyle.UNDECORATED);
    scene.setFill(null);
    stage.initStyle(StageStyle.TRANSPARENT);
    stage.show();
}