コード例 #1
0
ファイル: MenuButton.cpp プロジェクト: Blonder/TortoiseGit
BOOL CMenuButton::OnClicked()
{
	SetCurrentEntry(GetCurrentEntry());

	// let the parent handle the message the usual way
	return FALSE;
}
コード例 #2
0
DialogNodeExecutionStatus ResponseHandlerDialogNode::Execute (
    IDialogManager& dialogManager,
    DialogNodeExecutionContext& executionContext)
{
    for (EntryCollectionType::SizeType count = 0;
            count < entries_.Count ();
            ++count)
    {
        ResponseHandlerDialogNodeEntry* entry = entries_[count];

        if (!entry->RequirementIsFulfilled ())
            continue;

        ID entryID = ID (count);

        SetCurrentEntry (entryID);

        executionContext = DialogNodeExecutionContext (
                               entryID,
                               entry->GetMessages (),
                               entry->Action,
                               nullptr);

        dialogManager.TreatResponseProvider (*this);

        return DialogNodeExecutionStatus::Waiting;
    }

    return DialogNodeExecutionStatus::Over;
}
コード例 #3
0
ファイル: MenuButton.cpp プロジェクト: Blonder/TortoiseGit
INT_PTR CMenuButton::AddEntry(const CString& sEntry)
{
	INT_PTR ret = m_sEntries.Add(sEntry);
	m_btnMenu.AppendMenu(MF_STRING | MF_BYCOMMAND, m_sEntries.GetCount(), sEntry);
	if (m_sEntries.GetCount() == 2)
		m_bMenuIsActive = FALSE;

	if (ret == 0)
		SetCurrentEntry(ret);
	return ret;
}
コード例 #4
0
ファイル: MenuButton.cpp プロジェクト: YueLinHo/TortoiseGit
INT_PTR CMenuButton::AddEntry(const CString& sEntry, UINT uIcon /*= 0U*/)
{
	INT_PTR ret = m_sEntries.Add(sEntry);
	m_btnMenu.AppendMenuIcon(m_sEntries.GetCount(), sEntry, uIcon);
	if (m_sEntries.GetCount() == 2)
		m_bMenuIsActive = FALSE;

	if (ret == 0)
		SetCurrentEntry(ret);
	return ret;
}
コード例 #5
0
void            LogStream::AppendToEntry(const string entry, const char* txt, ...){
    SetCurrentEntry(entry);
    
    char buffer[512];

    va_list args;
    va_start( args, txt );
    vsnprintf( buffer, 512, txt, args );
    va_end( args );

    Append(string(buffer));
}
コード例 #6
0
void            LogStream::Clear(const string entry){
  SetCurrentEntry(entry);
  Clear(); 
}
コード例 #7
0
void            LogStream::SetOStream(const string entry, std::ostream & ostr){
  SetCurrentEntry(entry);
  SetOStream(ostr);
}
コード例 #8
0
void            LogStream::SetDeltaIndent(const string entry, int dIndent){
  SetCurrentEntry(entry);
  SetDeltaIndent(dIndent);
}
コード例 #9
0
void            LogStream::SetAutoPrint(const string entry, bool bAuto){
  SetCurrentEntry(entry);
  SetAutoPrint(bAuto);
}
コード例 #10
0
void            LogStream::Print(const string entry, int nbLines){
  SetCurrentEntry(entry);
  Print(nbLines);
}
コード例 #11
0
string          LogStream::GetLastString(const string entry){
  SetCurrentEntry(entry);
  return GetLastString();
}
コード例 #12
0
StringVector&   LogStream::GetStrings(const string entry, int nbLines){
  SetCurrentEntry(entry);
  return GetStrings(nbLines);  
}
コード例 #13
0
void            LogStream::AppendToEntry(const string entry, const string data){
  SetCurrentEntry(entry);
  Append(data); 
}