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


C++ reload函数代码示例

本文整理汇总了C++中reload函数的典型用法代码示例。如果您正苦于以下问题:C++ reload函数的具体用法?C++ reload怎么用?C++ reload使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: main


//.........这里部分代码省略.........
				return 0;
			case 'l':
				logp("-l <logfile> option obsoleted\n");
				break;
			case 'n':
				forking=0;
				break;
			case 'r':
				regex=optarg;
				break;
			case 's':
				strip=atoi(optarg);
				break;
			case 'v':
				printf("%s-%s\n", progname(), VERSION);
				return 0;
			case 'z':
				browsefile=optarg;
				break;
			case 'h':
			case '?':
			default:
				usage();
				return 1;
				break;
		}
	}
	if(optind<argc)
	{
		usage();
		return 1;
	}

	if(reload(&conf, configfile,
	  1 /* first time */,
	  0 /* no oldmax_children setting */,
	  0 /* no oldmax_status_children setting */)) return 1;

	if((act==ACTION_RESTORE || act==ACTION_VERIFY) && !backup)
	{
		logp("No backup specified. Using the most recent.\n");
		backup="0";
	}

	if(conf.mode==MODE_CLIENT)
	{
		if(orig_client && *orig_client)
		{
			if(!(conf.orig_client=strdup(orig_client)))
			{
				logp("out of memory\n");
				return 1;
			}
		}
	}

	if(conf.mode==MODE_SERVER
	  && (act==ACTION_STATUS || act==ACTION_STATUS_SNAPSHOT))
	{
		// Server status mode needs to run without getting the lock.
	}
	else
	{
		if(get_lock(conf.lockfile))
		{
			logp("Could not get lockfile.\n");
开发者ID:goneri,项目名称:burp,代码行数:67,代码来源:prog.c

示例2: reload

 void FontTexture::bind()
 {
     reload();
     glBindTexture(GL_TEXTURE_2D, id);
 }
开发者ID:femmebot,项目名称:new-chronotext-toolkit,代码行数:5,代码来源:FontManager.cpp

示例3: reload

void KreCategoriesListWidget::createCategory( const Element & category, int parent_id )
{
	reload( ForceReload );
}
开发者ID:eliovir,项目名称:krecipes,代码行数:4,代码来源:krecategorieslistwidget.cpp

示例4: SIGNAL

void PainterTerrain::setWaterAlgorithm(PathWaterAlgorithm *da){
    water_algorithm = da;
    render_tab = render_water;
    QObject::connect(water_algorithm, SIGNAL(reload()), this, SLOT(updateGL()));
    this->GLWidget::updateGL();
}
开发者ID:jtpefaur,项目名称:runnel,代码行数:6,代码来源:painterterrain.cpp

示例5: reload

void KOEventEditor::modified()
{
  // Play dumb, just reload the event. This dialog has become so complicated
  // that there is no point in trying to be smart here...
  reload();
}
开发者ID:akhuettel,项目名称:kdepim-noakonadi,代码行数:6,代码来源:koeventeditor.cpp

示例6: reload

void gRuleEditorWidget::on_btnRemoveEvent_clicked()
{
    if(ui->listEvents->selectedItems().count() == 0)return;
    m_conn.removeSenderEvent(ui->listEvents->currentRow());
    reload();
}
开发者ID:0x,项目名称:Jarvis,代码行数:6,代码来源:gruleeditorwidget.cpp

示例7: file_name_

ShadingModel::ShadingModel(std::string const& name,
                           std::string const& file_name)
    : file_name_(file_name), shader_stages_(4), name_(name) {

  reload();
}
开发者ID:4og,项目名称:guacamole,代码行数:6,代码来源:ShadingModel.cpp

示例8: create

void create()
{
  reload("tianzhu_huang_tang");
  set_name("╗к╠└", ({"huang tang", "huang", "tang"}));
开发者ID:gongfuPanada,项目名称:xyj2006,代码行数:4,代码来源:huang.c

示例9: SLOT

void KonqSideBarWebModule::pageLoaded() {
    if( reloadTimeout > 0 ) {
        QTimer::singleShot( reloadTimeout, this, SLOT(reload()) );
    }
}
开发者ID:theunbelievablerepo,项目名称:dolphin2.1,代码行数:5,代码来源:web_module.cpp

示例10: qDebug

ImageStatus ImageItem::render(const RenderSetting &setting, ImageModel *model)
{
    if (renderSetting() == setting && renderStatus() == IMAGE_STATUS_DONE)
    {
        qDebug("Image:%s is already ready\n", name().toStdString().c_str());
        return renderStatus();
    }

    // MUST NOT reload at this time
    setRenderStatus(IMAGE_STATUS_WAIT);
    qDebug("Render Image:%s!!! \n", name().toStdString().c_str());

    if (!(renderSetting() == setting) &&
        !model->getImagesMgr().makeEnoughMemory(tryCalcImageLength(
                                                setting.contentArea().width(),
                                                setting.contentArea().height(),
                                                QImage::Format_Indexed8),
                                                name(),
                                                model->renderPolicy()))
    {
        setRenderStatus(IMAGE_STATUS_ABORT);
        return renderStatus();
    }

    // if the data is null, reload the image
    if (needReload(setting) && !reload())
    {
        qWarning("Reload fails\n\n");
        setRenderStatus(IMAGE_STATUS_ABORT);
        return renderStatus();
    }

    if (data_ == 0)
    {
        setRenderStatus(IMAGE_STATUS_ABORT);
        return renderStatus();
    }

    int cur_area_size = data_->width() * data_->height();
    int scaled_area_size = setting.contentArea().width() * setting.contentArea().height();
    if (cur_area_size < scaled_area_size)
    {
        // pre-quantize
        quantize();
    }
    else if (cur_area_size > scaled_area_size)
    {
        dirty_ = true;
    }

    if (setting.rotation() != renderSetting().rotation())
    {
        rotate(setting.rotation());
    }

    if (setting.contentArea() != renderSetting().contentArea())
    {
        if (!scaled(setting.contentArea().size()))
        {
            setRenderStatus(IMAGE_STATUS_ABORT);
            return renderStatus();
        }
    }

    // post-quantize
    quantize();

    setRenderSetting(setting);
    setRenderStatus(IMAGE_STATUS_DONE);
    return renderStatus();
}
开发者ID:chenhbzl,项目名称:BooxApp,代码行数:71,代码来源:image_item.cpp

示例11: reload

ImageStatus ImageItem::renderThumbnail(const QRect &bounding_rect,
                                       QRect &display_area,
                                       shared_ptr<ImageThumbnail> thumbnail,
                                       ImageModel *model)
{
    // check the previous thumbnail image
    if (thumbnail->image() != 0)
    {
        if (thumbnail->size() != display_area.size())
        {
            thumbnail->clearPage();
        }
        else
        {
            return IMAGE_STATUS_DONE;
        }
    }

    // if there is no data being loaded, reload the image
    scoped_ptr<QImage> cur_data;
    if (data_ == 0)
    {
        reload();
    }
    cur_data.reset(new QImage(*data_));

    if (!display_area.isValid())
    {
        getThumbnailRectangle(bounding_rect, cur_data->size(), &display_area);
    }

    if (model->getThumbsMgr().makeEnoughMemory(tryCalcImageLength(
                                               display_area.width(),
                                               display_area.height(),
                                               QImage::Format_Indexed8),
                                               name(),
                                               model->renderPolicy()))
    {
        int width  = display_area.width();
        int height = display_area.height();

        int cur_area_size = cur_data->width() * cur_data->height();
        int scaled_area_size = width * height;
        bool dithered = false;
        if (cur_area_size < scaled_area_size)
        {
            // pre-dither
            dithering_strategy_->dither(cur_data.get());
            dithered = true;
        }

        if (cur_data->size() != display_area.size())
        {
            cur_data.reset(scaled(display_area.size(), cur_data.get()));
        }

        if (!dithered && ImageGlobalSettings::instance().needDither())
        {
            // post-dither
            dithering_strategy_->dither(cur_data.get());
        }

        thumbnail->setImage(cur_data.release());
        thumbnail->setOriginSize(actualSize());
        return IMAGE_STATUS_DONE;
    }
    return IMAGE_STATUS_FAIL;
}
开发者ID:chenhbzl,项目名称:BooxApp,代码行数:68,代码来源:image_item.cpp

示例12: reload

void AttributeManager::initialize()
{
    reload();
}
开发者ID:atheros,项目名称:manaserv,代码行数:4,代码来源:attributemanager.cpp

示例13: QObject

EnvMap::EnvMap(QProcess *process)
 : QObject(0), _process(process)
{
    reload();
}
开发者ID:sistux,项目名称:qink,代码行数:5,代码来源:envmap.cpp

示例14: create

void create()
{
  reload("wuji_xiaoer_er");
  set_name("店小二", ({"xiao er","xiaoer","xiao","waiter","er"}));
开发者ID:gongfuPanada,项目名称:mhxy2002,代码行数:4,代码来源:xiaoer.c

示例15: reload

// Reload the configuration using the specified configuration loader
bool Configuration::reload(ConfigLoader* configLoader)
{
	this->configLoader = configLoader;

	return reload();
}
开发者ID:GarysRefererence2014,项目名称:SoftHSMv2,代码行数:7,代码来源:Configuration.cpp


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