示例#1
0
bool IHISession::HandlePageScrollMouseWheel (const CString &sScroller, int iDelta)

//	HandlePageScrollMouseWheel
//
//	Handle mouse wheel

	{
	if (iDelta != 0)
		{
		IAnimatron *pList = GetPerformance(sScroller);
		if (pList)
			pList->Scroll(scrollRelative, -iDelta);

		return true;
		}
	else
		return false;
	}
示例#2
0
void CStatsSession::SetSelection (int iPos)

//	SetSelection
//
//	Sets the selection position

	{
	IAnimatron *pAni = GetPerformance(ID_GAME_STAT_PERFORMANCE);
	if (pAni == NULL)
		return;

	//	Set

	SelectGameStat(pAni, iPos, RectWidth(m_rcStats));

	//	Restart animation

	StartPerformance(ID_GAME_STAT_PERFORMANCE, CReanimator::SPR_FLAG_DELETE_WHEN_DONE);
	}
示例#3
0
wxString CppCheckSettings::GetOptions() const
{
	wxString options;
	if (GetStyle()) {
		options << wxT(" --enable=style ");
	}
	if (GetPerformance()) {
		options << wxT(" --enable=performance ");
	}
	if (GetPortability()) {
		options << wxT(" --enable=portability ");
	}
	if (GetUnusedFunctions()) {
		options << wxT(" --enable=unusedFunction ");
	}
	if (GetMissingIncludes()) {
		options << wxT(" --enable=missingInclude ");
	}
	if (GetInformation()) {
		options << wxT(" --enable=information ");
	}
	if (GetPosixStandards()) {
		options << wxT(" --std=posix ");
	}
	if (GetC99Standards()) {
		options << wxT(" --std=c99 ");
	}
	if (GetCpp11Standards()) {
		options << wxT(" --std=c++11 ");
	}
	if (GetForce()) {
		options << wxT("--force ");
	}

	// Now add any ticked suppressedwarnings
	std::map<wxString, wxString>::const_iterator iter = m_SuppressedWarnings1.begin();
	for (; iter != m_SuppressedWarnings1.end(); ++iter) {
		options << wxT(" --suppress=") << (*iter).first;
	}

	options << wxT(" --template gcc ");
	return options;
}
示例#4
0
//----------------------------------------------------------------------------
// PresentImage
//
// Here all the fun happens. lpPresInfo contains surface with current video image
// Call m_AlphaBlt->AlphaBlt to perform all the necessary transformation
//----------------------------------------------------------------------------
STDMETHODIMP
CMpegMovie::PresentImage(
    DWORD_PTR dwUserID,
    VMRPRESENTATIONINFO* lpPresInfo
    )
{
    // clear the background
    DDBLTFX ddFX;
    INITDDSTRUCT(ddFX);

    RECT rcS = {0, 0, 640, 480};
    RECT rcD = {128, 96, 512, 384};
    RECT rcDt ={128, 0, 512, 288};

    m_lpDefWC->GetVideoPosition(&rcS, NULL);
    if( g_ss.bShowTwist )
    {
        m_AlphaBlt->AlphaBlt(&rcDt, lpPresInfo->lpSurf, &rcS, 0xFF);
    }
    else
    {
        m_AlphaBlt->AlphaBlt(&rcD, lpPresInfo->lpSurf, &rcS, 0xFF);
    }

    m_lpSurf->Flip(NULL,0);

    if( g_ss.bShowStatistics && m_Qp)
    {
        // call IQualProp functions here to get performance statistics
        GetPerformance();
    }

    // Show the scene
    m_pDDObject.GetFB()->Flip(NULL, /*DDFLIP_WAIT*/ 0);

    return S_OK;
}
wxString CppCheckSettings::GetOptions() const
{
    wxString options;
    if(GetStyle()) {
        options << wxT(" --enable=style ");
    }
    if(GetPerformance()) {
        options << wxT(" --enable=performance ");
    }
    if(GetPortability()) {
        options << wxT(" --enable=portability ");
    }
    if(GetUnusedFunctions()) {
        options << wxT(" --enable=unusedFunction ");
    }
    if(GetMissingIncludes()) {
        options << wxT(" --enable=missingInclude ");
    }
    if(GetInformation()) {
        options << wxT(" --enable=information ");
    }
    if(GetPosixStandards()) {
        options << wxT(" --std=posix ");
    }
    if(GetC99Standards()) {
        options << wxT(" --std=c99 ");
    }
    if(GetCpp11Standards()) {
        options << wxT(" --std=c++11 ");
    }
    if(GetForce()) {
        options << wxT("--force ");
    }
    if(GetJobs() > 1) {
        options << wxT("-j") << GetJobs() << " ";
    }
    if(GetCheckConfig()) {
        options << wxT("--check-config "); // Though this turns off other checks, afaict it does not harm to emit them
    }

    // Now add any ticked suppressedwarnings
    std::map<wxString, wxString>::const_iterator iter = m_SuppressedWarnings1.begin();
    for(; iter != m_SuppressedWarnings1.end(); ++iter) {
        options << wxT(" --suppress=") << (*iter).first << " ";
    }

    // IncludeDirs
    for(size_t n = 0; n < m_IncludeDirs.GetCount(); ++n) {
        wxString item = m_IncludeDirs.Item(n);
        item.Trim().Trim(false);
        if(!item.empty()) {
            options << " -I" << item << " ";
        }
    }
    if(m_SuppressSystemIncludes) {
        options << wxT(" --suppress=") << "missingIncludeSystem ";
    }

    // (Un)Definitions
    for(size_t n = 0; n < m_definitions.GetCount(); ++n) {
        wxString item = m_definitions.Item(n);
        item.Trim().Trim(false);
        if(!item.empty()) {
            options << " -D" << item << " ";
        }
    }
    for(size_t n = 0; n < m_undefines.GetCount(); ++n) {
        wxString item = m_undefines.Item(n);
        item.Trim().Trim(false);
        if(!item.empty()) {
            options << " -U" << item << " ";
        }
    }

    options << wxT(" --template gcc ");
    return options;
}
示例#6
0
bool IHISession::HandlePageScrollKeyDown (const CString &sScroller, int iVirtKey, DWORD dwKeyData)

//	HandlePageScrollKeyDown
//
//	Handle keyboard interface for scrolling a simple page.

	{
	EScrollTypes iScroll;
	int iScrollDist;

	switch (iVirtKey)
		{
		case VK_DOWN:
			iScroll = scrollRelative;
			iScrollDist = 50;
			break;

		case VK_UP:
			iScroll = scrollRelative;
			iScrollDist = -50;
			break;

		case VK_NEXT:
			iScroll = scrollRelative;
			iScrollDist = 512;
			break;

		case VK_PRIOR:
			iScroll = scrollRelative;
			iScrollDist = -512;
			break;

		case VK_END:
			iScroll = scrollToEnd;
			iScrollDist = 0;
			break;

		case VK_HOME:
			iScroll = scrollToHome;
			iScrollDist = 0;
			break;

		default:
			iScroll = scrollNone;
			iScrollDist = 0;
			break;
		}

	//	Scroll

	if (iScroll != scrollNone)
		{
		IAnimatron *pList = GetPerformance(sScroller);
		if (pList)
			pList->Scroll(iScroll, iScrollDist);

		return true;
		}
	else
		return false;
	}