Exemplo n.º 1
0
  private void loadShader(String source) {
    setSourceButtonDefault();
    errorPopup.dismiss();
    errorPopupVisible = false;
    shaderEditor.errorLine = 0;

    shaderView.onPause();
    shaderView.renderer.fragmentShader = source;
    shaderView.onResume();
  }
Exemplo n.º 2
0
  @Override
  public void onResume() {
    super.onResume();

    shaderView.onResume();
    dataSource.open();

    loadPreferences();
  }
Exemplo n.º 3
0
  @Override
  public void onPause() {
    super.onPause();

    if (shaderEditor.dirty) {
      saveShader();
      shaderEditor.dirty = false;
    }

    shaderView.onPause();
    dataSource.close();
  }