private void OnGUI() { //Bootstrap.Log("FadeComponent.OnGUI()"); //Bootstrap.Log(" _alpha:" + _alpha.ToString()); if (0.0f < _alpha) { _UIBox.Draw(); } }
public void UpdateUI(bool tf) { if (!tf) { return; } float scale = 1 * DeviceDependentScale; mAboutTitleHeight = 80.0f * scale; mBox.Draw(); GUI.Box(new Rect(0, 0, Screen.width, mAboutTitleHeight), string.Empty, mAboutTitleBgStyle); GUI.Box(new Rect(ABOUT_TEXT_MARGIN * DeviceDependentScale, 0, Screen.width, mAboutTitleHeight), mTitle, mAboutTitleBgStyle); float width = Screen.width / 1.5f; //float height = startButtonStyle.normal.background.height * scale; float height = mOKButtonBgStyle.normal.background.height * scale; mStartButtonAreaHeight = height + 2 * (START_BUTTON_VERTICAL_MARGIN * scale); float left = Screen.width / 2 - width / 2; float top = Screen.height - mStartButtonAreaHeight + START_BUTTON_VERTICAL_MARGIN * scale; GUI.skin = mUISkin; GUILayout.BeginArea(new Rect(ABOUT_TEXT_MARGIN * DeviceDependentScale, mAboutTitleHeight + 5 * DeviceDependentScale, Screen.width - (ABOUT_TEXT_MARGIN * DeviceDependentScale), Screen.height - (mStartButtonAreaHeight) - mAboutTitleHeight - 5 * DeviceDependentScale)); mScrollPosition = GUILayout.BeginScrollView(mScrollPosition, false, false, GUILayout.Width(Screen.width - (ABOUT_TEXT_MARGIN * DeviceDependentScale)), GUILayout.Height(Screen.height - mStartButtonAreaHeight - mAboutTitleHeight)); GUILayout.BeginHorizontal(); GUILayout.FlexibleSpace(); GUILayout.Label(m_AboutText.text); GUILayout.FlexibleSpace(); GUILayout.EndHorizontal(); GUILayout.EndScrollView(); GUILayout.EndArea(); // if button was pressed, remember to make sure this event is not interpreted as a touch event somewhere else if (GUI.Button(new Rect(left, top, width, height), "OK", mOKButtonBgStyle)) { if (this.OnStartButtonTapped != null) { this.OnStartButtonTapped(); } } }
public void UpdateUI(bool tf) { if (!tf) { return; } mBox.Draw(); mAboutLabel.Draw(); mBackgroundTextureLabel.Draw(); mCameraFlashSettings.Draw(); mAutoFocusSetting.Draw(); mCloseButton.Draw(); }
public void UpdateUI(bool tf) { if (!tf) { return; } mBox.Draw(); mVideoPlaybackLabel.Draw(); mAboutLabel.Draw(); mExtendedTracking.Draw(); mCameraFlashSettings.Draw(); mAutoFocusSetting.Draw(); mCameraLabel.Draw(); mCameraFacing.Draw(); mCloseButton.Draw(); }
public void UpdateUI(bool tf) { if (!tf) { return; } mBox.Draw(); mAboutLabel.Draw(); mImageTargetLabel.Draw(); mExtendedTracking.Draw(); mCameraFlashSettings.Draw(); mAutoFocusSetting.Draw(); mCameraLabel.Draw(); mCameraFacing.Draw(); mDataSet.Draw(); mDataSetLabel.Draw(); mCloseButton.Draw(); }