本文整理汇总了C++中PD_Document::isPieceTableChanging方法的典型用法代码示例。如果您正苦于以下问题:C++ PD_Document::isPieceTableChanging方法的具体用法?C++ PD_Document::isPieceTableChanging怎么用?C++ PD_Document::isPieceTableChanging使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PD_Document
的用法示例。
在下文中一共展示了PD_Document::isPieceTableChanging方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: autoUpdateMC
/*!
* Autoupdater of the dialog.
*/
void AP_Dialog_SplitCells::autoUpdateMC(UT_Worker * pTimer)
{
UT_return_if_fail(pTimer);
// this is a static callback method and does not have a 'this' pointer
AP_Dialog_SplitCells * pDialog = static_cast<AP_Dialog_SplitCells *>(pTimer->getInstanceData());
if (pDialog->m_bDestroy_says_stopupdating != true)
{
FV_View * pView = 0;
PD_Document * pDoc = NULL;
if (XAP_Frame * pFrame = pDialog->getApp()->getLastFocussedFrame())
{
pView = static_cast<FV_View *>(pFrame->getCurrentView());
}
if (pView)
{
pDoc = pView->getDocument();
}
if (!pView || (pDoc && !pDoc->isPieceTableChanging()))
{
pDialog->m_bAutoUpdate_happening_now = true;
pDialog->setAllSensitivities();
pDialog->m_bAutoUpdate_happening_now = false;
}
}
}
示例2: calculateValue
bool fp_FieldTableSumCols::calculateValue(void)
{
FV_View * pView = _getView();
pf_Frag_Strux* tableSDH= NULL;
UT_sint32 numRows =0;
UT_sint32 numCols = 0;
bUseCurrency = false;
cCurrency = '$';
pf_Frag_Strux* sdh = getBlock()->getStruxDocHandle();
PD_Document * pDoc = getBlock()->getDocument();
if(pDoc->isPieceTableChanging())
{
return false;
}
if(getLine() == NULL)
{
return false;
}
fp_Container * pCol = getLine()->getColumn();
if(pCol == NULL)
{
return false;
}
fp_ShadowContainer * pShad =NULL;
fl_HdrFtrShadow * pShadL = NULL;
if(pCol->getContainerType() == FP_CONTAINER_COLUMN_SHADOW)
{
pShad = static_cast<fp_ShadowContainer *>(pCol);
pShadL = pShad->getShadow();
}
PT_DocPosition pos = pDoc->getStruxPosition(sdh)+1;
pDoc->getStruxOfTypeFromPosition(pos,PTX_SectionTable,&tableSDH);
pDoc-> getRowsColsFromTableSDH(tableSDH, pView->isShowRevisions(), pView->getRevisionLevel(), &numRows, &numCols);
UT_UTF8String sValF;
if(!pView->isInTable(pos))
{
sValF = "???";
return _setValue(sValF.ucs4_str().ucs4_str());
}
fl_CellLayout * pCell = NULL;
UT_sint32 myLeft,myRight,myTop,myBot;
pView->getCellParams(pos,&myLeft,&myRight,&myTop,&myBot);
UT_sint32 col = 0;
UT_sint32 row = myTop;
UT_sint32 lastCol = -1;
double dSum = 0.0;
for(col = 0; col < numCols; col++)
{
pf_Frag_Strux* sdhCell = pDoc->getCellSDHFromRowCol(tableSDH,true,99999,row,col);
UT_sint32 i = getBlock()->getDocLayout()->getLID();
fl_ContainerLayout* fmtCell = pDoc->getNthFmtHandle(sdhCell,i);
pCell = static_cast<fl_CellLayout *>(fmtCell);
if(pCell->getLeftAttach() == lastCol)
{
continue;
}
if((pCell->getTopAttach() == myTop) && (pCell->getLeftAttach() == myLeft))
{
continue;
}
UT_GrowBuf grText;
pCell->appendTextToBuf(grText);
if(grText.getLength() == 0)
{
fl_ContainerLayout * pC = pCell->getFirstLayout();
while(pC)
{
if(pC->getContainerType() == FL_CONTAINER_BLOCK)
{
fl_BlockLayout * pBL = static_cast<fl_BlockLayout *>(pC);
if(pShadL)
{
pBL = static_cast<fl_BlockLayout *>(pShadL->findMatchingContainer(pBL));
}
if(pBL == NULL)
{
continue;
}
fp_Run * pRun = pBL->getFirstRun();
while(pRun)
{
if(pRun->getType() == FPRUN_FIELD)
{
fp_FieldRun * pFRun = static_cast<fp_FieldRun *>(pRun);
const UT_UCS4Char * szVal = pFRun->getValue();
sValF.clear();
sValF.appendUCS4(szVal);
dSum += dGetVal(sValF.utf8_str());
pRun = NULL;
pC = NULL;
break;
}
pRun = pRun->getNextRun();
}
}
if(pC)
{
pC = pC->getNext();
//.........这里部分代码省略.........