本文整理匯總了C++中GetManager函數的典型用法代碼示例。如果您正苦於以下問題:C++ GetManager函數的具體用法?C++ GetManager怎麽用?C++ GetManager使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了GetManager函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。
示例1: SIPEndPoint
/* The class */
Opal::Sip::EndPoint::EndPoint (Opal::EndPoint & _endpoint,
const Ekiga::ServiceCore& _core): SIPEndPoint (_endpoint),
core (_core)
{
/* Timeouts */
SetRetryTimeouts (500, 4000);
SetMaxRetries (20);
/* Update the User Agent */
SetUserAgent ("Ekiga/" PACKAGE_VERSION);
/* Ready to take calls */
GetManager ().AddRouteEntry("sip:.* = pc:*");
GetManager ().AddRouteEntry("pc:.* = sip:<da>");
/* Keepalive */
PTimeInterval timeout;
KeepAliveType type;
GetKeepAlive (timeout, type);
SetKeepAlive (timeout, KeepAliveByOPTION);
}
示例2:
/* virtual */
OP_STATUS
OpScopeConsoleLogger::OnPostInitialization()
{
#ifdef SCOPE_WINDOW_MANAGER_SUPPORT
if (OpScopeServiceManager *manager = GetManager())
window_manager = OpScopeFindService<OpScopeWindowManager>(manager, "window-manager");
if (!window_manager)
return OpStatus::ERR_NULL_POINTER;
#endif // SCOPE_WINDOW_MANAGER_SUPPORT
return OpStatus::OK;
}
示例3: GetManager
void DisplayElement::SetManager (DisplayManager *pManager)
{
if (pManager != GetManager())
{
DisplayManager *pOldManager = GetManager();
mManager.Set(pManager);
if (pOldManager)
{
pOldManager->RemoveElementReferences(this); // remove all references to this element
}
// Propogate down the tree
DisplayElement *pChild = mpFirstChild;
while (pChild)
{
pChild->SetManager(pManager);
pChild = pChild->mpNext;
}
}
}
示例4: OnSkinChange
int CPluginWnd::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
if ( CMDIChildWnd::OnCreate( lpCreateStruct ) == -1 ) return -1;
m_bAlert = 1982;
OnSkinChange();
m_bAlert = FALSE;
GetManager()->Add( this );
return 0;
}
示例5: GetManager
bool ButtonBase::OnMouseUp(float x, float y, int button)
{
if( GetManager()->GetCapture() == this )
{
GetManager()->SetCapture(NULL);
bool click = (GetState() == statePushed);
WindowWeakPtr wwp(this);
if( eventMouseUp )
INVOKE(eventMouseUp) (x, y); // handler may destroy this object
if( click && wwp.Get() )
{
OnClick(); // handler may destroy this object
if( eventClick && wwp.Get() )
INVOKE(eventClick) (); // handler may destroy this object
}
if( wwp.Get() && GetEnabled() ) // handler may disable this button
SetState(stateHottrack);
return true;
}
return false;
}
示例6: GetManager
int ManagerList::GetConnectionRate(TargetType type)
{
int m, mgr_count, mgr_result;
if (!(mgr_count = ManagerCount(type)))
return AMBIGUOUS_VALUE;
// Get the value of the first manager.
mgr_result = GetManager(0, type)->GetConnectionRate(type);
// Compare each manager's value with the first manager.
for (m = 1; m < mgr_count; m++) {
if (GetManager(m, type)->WorkerCount(type) &&
mgr_result != GetManager(m, type)->GetConnectionRate(type)) {
// The values are not the same.
return AMBIGUOUS_VALUE;
}
}
// All managers have the same value.
return mgr_result;
}
示例7: PreUpdate
void dAnimIKController::PreUpdate(dFloat timestep, int threadIndex)
{
// dAssert(0);
// RigidBodyToStates();
if (m_animationTree) {
m_animationTree->Update(timestep);
}
// m_solver.Update(timestep);
// UpdateJointAcceleration();
dAnimIKManager* const manager = (dAnimIKManager*)GetManager();
manager->UpdatePlayer(this, timestep);
}
示例8: return
//
// Get the fallback placement
//
Placement * Placement::GetFallback()
{
if (fallback.Null())
{
return (NULL);
}
else
{
LOG_AI(("Getting fallback '%s'", fallback.str))
return (&GetManager().GetPlacement(fallback));
}
}
示例9: ErrorMessage
//
// Verify that all assigned configuration parameters are valid.
//
BOOL ManagerList::InvalidSetup()
{
int m, w;
Manager *mgr;
Worker *wkr;
BOOL nonidle_worker_with_targets = FALSE;
BOOL all_workers_idle = TRUE;
// Verify that at least one spec was assigned, even if Idle.
if ( !GetMaxAccessSpecCount() )
{
ErrorMessage( "You must assign at least one access specification "
"to a worker." );
return TRUE;
}
// We need to loop through all workers of all managers to verify
// their assigned specs are valid.
for ( m = 0; m < ManagerCount(); m++ )
{
mgr = GetManager( m );
if ( mgr->InvalidSetup() )
return TRUE;
// Verify that at least one worker has targets assigned with a
// non-idle spec or all specs are idle.
for ( w = 0; w < mgr->WorkerCount(); w++ )
{
wkr = mgr->GetWorker( w );
// Keep track if all workers have only the idle spec.
if ( wkr->AccessSpecCount() != wkr->IdleAccessSpecCount() )
{
all_workers_idle = FALSE;
// Keep track if any non-idle worker has targets.
if ( wkr->TargetCount() )
nonidle_worker_with_targets = TRUE;
}
}
}
// Verify that at least one worker has targets assigned with a
// non-idle spec or all specs are idle.
if ( !all_workers_idle && !nonidle_worker_with_targets )
{
ErrorMessage( "If no worker has targets selected, then all workers "
"must have the idle spec assigned." );
return TRUE;
}
return FALSE;
}
示例10:
bool
Iop::PowerOff( SsapiResponder *pResponder ){
if( m_serviceState ){
pResponder->RespondToRequest( SSAPI_EXCEPTION_INVALID_STATE, CTS_SSAPI_EXCEPTION_DEVICE_IN_SERVICE );
return true;
}
((DeviceManager *)GetManager())->ChangeIopPowerState( this,
true,
pResponder );
return true;
}
示例11: UIWindow
Dialog::Dialog(UIWindow *parent, float width, float height, bool modal)
: UIWindow(/*modal ? new Substrate(parent) :*/ parent)
, _mouseX(0)
, _mouseY(0)
, _easyMove(false)
{
SetTexture("ui/window", false);
Resize(width, height);
Move(std::floor((parent->GetWidth() - GetWidth()) / 2), std::floor((parent->GetHeight() - GetHeight()) / 2));
SetDrawBorder(true);
SetDrawBackground(true);
GetManager().SetFocusWnd(this);
}
示例12: GetManager
~ManagerMediator()
{
MT4Adapter::IntegrationMT4Server* manager = GetManager();
if (manager != NULL)
{
manager->UnInitialize();
}
CloseHandle(_mutexHandle);
_mutexHandle = NULL;
gcHandle.Free();
}
示例13: GetManager
// ok, this is a silly thing to do but it will work.
void HTMLBodyDisplay::SetHtmlFocus (HTMLElement *pElement)
{
if (!GetManager())
{
return;
}
if (!(mKeyCatcher1.mFlags & DISPLAY_FLAG_FOCUS) && (mKeyCatcher2.GetElement() != pElement))
{
// this is the default case
mKeyCatcher1.SetElement(pElement);
GetManager()->SetFocus(&mKeyCatcher1);
mKeyCatcher2.SetElement(0);
}
else if (!(mKeyCatcher2.mFlags & DISPLAY_FLAG_FOCUS) && (mKeyCatcher1.GetElement() != pElement))
{
// give it to key catcher number 2
mKeyCatcher2.SetElement(pElement);
GetManager()->SetFocus(&mKeyCatcher2);
mKeyCatcher1.SetElement(0);
}
}
示例14: GetWorker
//
// Retrieving a pointer to a specified worker item in the view.
//
HTREEITEM CWorkerView::GetWorker(Worker * worker)
{
HTREEITEM hworker;
// Get the first worker.
hworker = m_TWorkers.GetChildItem(GetManager(worker->manager));
// Loop through manager's workers until we find the correct one.
while (m_TWorkers.GetItemData(hworker) != (DWORD_PTR) worker)
hworker = m_TWorkers.GetNextSiblingItem(hworker);
return hworker;
}
示例15: ManagerCount
//
// Disambiguate same-named managers. This allows managers
// to be uniquely identified in saved files and other places.
// This should be called any time managers are added, removed, or renamed.
//
void ManagerList::IndexManagers()
{
Manager *mgr, *othermgr;
int count_up, count_down;
const int mgr_count = ManagerCount();
for (count_up = 0; count_up < mgr_count; count_up++) {
mgr = GetManager(count_up);
mgr->id = 1; // Assume this is unique, unless proven otherwise.
for (count_down = count_up - 1; count_down >= 0; count_down--) {
othermgr = GetManager(count_down);
if (CString(mgr->name).CompareNoCase(othermgr->name) == 0) {
// If the managers' names are identical, assign
// this manager an ID value one greater.
mgr->id = othermgr->id + 1;
break;
}
}
}
}