当前位置: 首页>>代码示例>>C++>>正文


C++ BRow::HasLatch方法代码示例

本文整理汇总了C++中BRow::HasLatch方法的典型用法代码示例。如果您正苦于以下问题:C++ BRow::HasLatch方法的具体用法?C++ BRow::HasLatch怎么用?C++ BRow::HasLatch使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BRow的用法示例。


在下文中一共展示了BRow::HasLatch方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: DoPriority

void MainWindow::DoPriority(int32 priority)
{
	BRow*		selected = NULL;
	while ((selected = teamView->CurrentSelection(selected))) {
		// is a team or thread?
		if (selected->HasLatch())
			for (int i = 0; i < teamView->CountRows(selected); i++)
				set_thread_priority(((ThreadItem *)teamView->RowAt(i, selected))->thread, priority);
		else
			set_thread_priority(((ThreadItem *)selected)->thread, priority);
	}
}
开发者ID:HaikuArchives,项目名称:Slayer,代码行数:12,代码来源:MainWindow.cpp

示例2: DoResume

void MainWindow::DoResume(void)
{
	BRow*		selected = NULL;
	while ((selected = teamView->CurrentSelection(selected))) {
		// is a team or thread?
		if (selected->HasLatch())
			for (int i = 0; i < teamView->CountRows(selected); i++)
				resume_thread(((ThreadItem *)teamView->RowAt(i, selected))->thread);
		else
			resume_thread(((ThreadItem *)selected)->thread);
	}
}
开发者ID:HaikuArchives,项目名称:Slayer,代码行数:12,代码来源:MainWindow.cpp

示例3: DoKill

void MainWindow::DoKill(void)
{
	BRow*		selected = NULL;
	while ((selected = teamView->CurrentSelection(selected))) {
		if (selected->HasLatch())
			kill_team(((TeamItem *)selected)->team);
		else
			kill_thread(((ThreadItem *)selected)->thread);

		if (teamView->IndexOf(selected) == teamView->CountRows() - 1)
			teamView->MoveToRow(teamView->IndexOf(selected) - 1);
		else
			teamView->MoveToRow(teamView->IndexOf(selected) + 1);
	}
}
开发者ID:HaikuArchives,项目名称:Slayer,代码行数:15,代码来源:MainWindow.cpp

示例4: CountItems

void
PriorityMenu::Update()
{
	BRow* selected = fTeamListView->CurrentSelection(NULL);
	int32 priority;
	bool enabled = selected != NULL;
	
	if (enabled && fTeamListView->CurrentSelection(selected) == NULL && !selected->HasLatch()) 
		priority = ((ThreadItem *)selected)->priority;
	else 
		priority = -1;

	if (priority != fPriority || fEnabled != enabled)
	{   
		fPriority = priority;
		fEnabled = enabled;
		if (CountItems() > 0) 
			RemoveItems(0, CountItems(), true);
		if (CountItems() < 1)
			BuildMenu();
	}

}
开发者ID:HaikuArchives,项目名称:Slayer,代码行数:23,代码来源:PriorityMenu.cpp


注:本文中的BRow::HasLatch方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。