public void setIconLayout(IconLayout iconLayout) { HomeProperty home = MainForm.m_mainForm.m_home; if (home == null) { return; } if (0 > iconLayout.m_pagePos && 0 <= iconLayout.m_iconPos) { m_iconPos_ = iconLayout.m_iconPos; return; } if (0 > iconLayout.m_iconPos && 0 <= iconLayout.m_pagePos) { m_pagePos_ = iconLayout.m_pagePos; return; } if (!MainForm.m_mainForm.m_load) { IconParam iconParam = home.m_bgParam[iconLayout.m_pagePos].m_iconLayouts[iconLayout.m_iconPos]; if (iconParam != null) { if (iconLayout.m_pagePos != m_pagePos && iconLayout.m_pagePos == MainForm.m_mainForm.homeScreenTab.SelectedIndex) { iconParam.unsetHomePanel(); } home.m_bgParam[m_pagePos].m_iconLayouts[m_iconPos] = iconParam; iconParam.m_pagePos_ = m_pagePos; iconParam.m_iconPos_ = m_iconPos; if (m_pagePos == MainForm.m_mainForm.homeScreenTab.SelectedIndex) { iconParam.setHomePanel(m_iconPos, home.m_bgParam[m_pagePos].m_fontColor); } } else { home.m_bgParam[m_pagePos].m_iconLayouts[m_iconPos] = null; } } if (iconLayout.m_pagePos != m_pagePos && m_pagePos == MainForm.m_mainForm.homeScreenTab.SelectedIndex) { unsetHomePanel(); } home.m_bgParam[iconLayout.m_pagePos].m_iconLayouts[iconLayout.m_iconPos] = this; if (iconLayout.m_pagePos == MainForm.m_mainForm.homeScreenTab.SelectedIndex) { setHomePanel(iconLayout.m_iconPos, home.m_bgParam[iconLayout.m_pagePos].m_fontColor); } m_pagePos_ = iconLayout.m_pagePos; m_iconPos_ = iconLayout.m_iconPos; MainForm.m_mainForm.setBackHomePictureBox(); if (!MainForm.m_mainForm.m_refreshInvalid) { MainForm.m_mainForm.homePropertyGrid.Refresh(); } }
public void initIconLayout(HomeProperty homeProperty, IconLayout iconLayout) { m_pagePos_ = iconLayout.m_pagePos; m_iconPos_ = iconLayout.m_iconPos; if (0 <= m_pagePos && 0 <= m_iconPos) { homeProperty.m_bgParam[m_pagePos].m_iconLayouts[m_iconPos] = this; } }
public void resetLayout(bool bLoad = false) { MainForm.m_mainForm.resetHomePanel(); for (int i = 0; i < m_bgParam_.Length; i++) { for (int j = 0; j < m_bgParam_[i].m_iconLayouts.Length; j++) { m_bgParam_[i].m_iconLayouts[j] = null; } } if (bLoad) { IconLayout iconLayout = new IconLayout(-1, -1); m_browser.initIconLayout(this, iconLayout); m_video.initIconLayout(this, iconLayout); m_music.initIconLayout(this, iconLayout); m_ps3Link.initIconLayout(this, iconLayout); m_party.initIconLayout(this, iconLayout); m_trophy.initIconLayout(this, iconLayout); m_near.initIconLayout(this, iconLayout); m_hostCollabo.initIconLayout(this, iconLayout); m_welcomePark.initIconLayout(this, iconLayout); m_ps4Link.initIconLayout(this, iconLayout); m_friend.initIconLayout(this, iconLayout); m_email.initIconLayout(this, iconLayout); m_calendar.initIconLayout(this, iconLayout); m_store.initIconLayout(this, iconLayout); m_message.initIconLayout(this, iconLayout); m_parental.initIconLayout(this, iconLayout); m_camera.initIconLayout(this, iconLayout); m_settings.initIconLayout(this, iconLayout); m_power.initIconLayout(this, iconLayout); } else if (MainForm.m_mainForm.m_mode == Mode.Vita) { m_browser.initIconLayout(this, s_vitaIconLayout[0]); m_video.initIconLayout(this, s_vitaIconLayout[1]); m_music.initIconLayout(this, s_vitaIconLayout[2]); m_ps3Link.initIconLayout(this, s_vitaIconLayout[3]); m_party.initIconLayout(this, s_vitaIconLayout[4]); m_trophy.initIconLayout(this, s_vitaIconLayout[5]); m_near.initIconLayout(this, s_vitaIconLayout[6]); m_hostCollabo.initIconLayout(this, s_vitaIconLayout[7]); m_welcomePark.initIconLayout(this, s_vitaIconLayout[8]); m_ps4Link.initIconLayout(this, s_vitaIconLayout[9]); m_friend.initIconLayout(this, s_vitaIconLayout[10]); m_email.initIconLayout(this, s_vitaIconLayout[11]); m_calendar.initIconLayout(this, s_vitaIconLayout[12]); m_store.initIconLayout(this, s_vitaIconLayout[13]); m_message.initIconLayout(this, s_vitaIconLayout[14]); m_parental.initIconLayout(this, s_vitaIconLayout[15]); m_camera.initIconLayout(this, s_vitaIconLayout[16]); m_settings.initIconLayout(this, s_vitaIconLayout[17]); m_power.initIconLayout(this, s_vitaIconLayout[18]); } else if (Mode.VitaTV == MainForm.m_mainForm.m_mode) { m_browser.initIconLayout(this, s_vitaTvIconLayout[0]); m_video.initIconLayout(this, s_vitaTvIconLayout[1]); m_music.initIconLayout(this, s_vitaTvIconLayout[2]); m_ps3Link.initIconLayout(this, s_vitaTvIconLayout[3]); m_party.initIconLayout(this, s_vitaTvIconLayout[4]); m_trophy.initIconLayout(this, s_vitaTvIconLayout[5]); m_near.initIconLayout(this, s_vitaTvIconLayout[6]); m_hostCollabo.initIconLayout(this, s_vitaTvIconLayout[7]); m_welcomePark.initIconLayout(this, s_vitaTvIconLayout[8]); m_ps4Link.initIconLayout(this, s_vitaTvIconLayout[9]); m_friend.initIconLayout(this, s_vitaTvIconLayout[10]); m_email.initIconLayout(this, s_vitaTvIconLayout[11]); m_calendar.initIconLayout(this, s_vitaTvIconLayout[12]); m_store.initIconLayout(this, s_vitaTvIconLayout[13]); m_message.initIconLayout(this, s_vitaTvIconLayout[14]); m_parental.initIconLayout(this, s_vitaTvIconLayout[15]); m_camera.initIconLayout(this, s_vitaTvIconLayout[16]); m_settings.initIconLayout(this, s_vitaTvIconLayout[17]); m_power.initIconLayout(this, s_vitaTvIconLayout[18]); } }