示例#1
0
void PointMan::SetColorScheme( PI_ColorScheme cs )
{
    //ProcessIcons( g_ODStyleManager->GetCurrentStyle() );

    //    Iterate on the ODPoint list, requiring each to reload icon
    m_ColourScheme = cs;
    wxODPointListNode *node = m_pODPointList->GetFirst();
    while( node ) {
        ODPoint *pr = node->GetData();
        pr->SetColourScheme(cs);
        pr->ReLoadIcon();
        node = node->GetNext();
    }
}
示例#2
0
void EBL::CentreOnLatLon( double lat, double lon )
{
    ODPoint *pStartPoint = m_pODPointList->GetFirst()->GetData();
    pStartPoint->m_lat = lat;
    pStartPoint->m_lon = lon;
    pStartPoint->m_ODPointName = _("Start");
    if(pStartPoint->GetIconName() != wxEmptyString) {
        pStartPoint->SetIconName( g_sEBLStartIconName );
        pStartPoint->ReLoadIcon();
    }
    m_bCentreOnBoat = false;
    m_bSaveUpdates = true;
    
    UpdateEBL();
    if(g_pEBLPropDialog && g_pEBLPropDialog->IsShown())
        g_pEBLPropDialog->UpdateProperties();
    
    RequestRefresh( g_ocpn_draw_pi->m_parent_window );
    return;
}
示例#3
0
void EBL::CentreOnLatLon( double lat, double lon )
{
    ODPoint *pStartPoint = m_pODPointList->GetFirst()->GetData();
    ODPoint *pEndPoint = m_pODPointList->GetLast()->GetData();
    pStartPoint->m_lat = lat;
    pStartPoint->m_lon = lon;
    DistanceBearingMercator_Plugin(pEndPoint->m_lat, pEndPoint->m_lon, pStartPoint->m_lat, pStartPoint->m_lon, &m_dEBLAngle, &m_dLength);
    m_bRotateWithBoat = false;
    m_bCentreOnBoat = false;
    pStartPoint->m_ODPointName = _("Start");
    if(pStartPoint->GetIconName() != wxEmptyString) {
        pStartPoint->SetIconName( g_sEBLStartIconName );
        pStartPoint->ReLoadIcon();
    }
    m_bCentreOnBoat = false;
    m_bSaveUpdates = true;
    
    UpdateEBL();
    if(g_pEBLPropDialog && g_pEBLPropDialog->IsShown())
        g_pEBLPropDialog->UpdateProperties();
    
    RequestRefresh( g_ocpn_draw_pi->m_parent_window );
    return;
}