• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ reload函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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


示例16: create

void create()
{
  reload("zhuzi_wan_koufu");
  set_name("万口福", ({"wan koufu", "wan"}));
开发者ID:gongfuPanada,项目名称:xyj2006,代码行数:4,代码来源:wan.c


示例17: do_action


//.........这里部分代码省略.........
		case ACT_MAIN_OPEN_NEW_TAB:
			open_uri_in_new_tab(ses, NULL, 0, 1);
			break;

		case ACT_MAIN_OPEN_NEW_TAB_IN_BACKGROUND:
			open_uri_in_new_tab(ses, NULL, 1, 1);
			break;

		case ACT_MAIN_OPEN_NEW_WINDOW:
			open_in_new_window(term, send_open_new_window, ses);
			break;

		case ACT_MAIN_OPEN_OS_SHELL:
			exec_shell(term);
			break;

		case ACT_MAIN_OPTIONS_MANAGER:
			options_manager(ses);
			break;

		case ACT_MAIN_QUIT:
			exit_prog(ses, 1);
			break;

		case ACT_MAIN_REALLY_QUIT:
			exit_prog(ses, 0);
			break;

		case ACT_MAIN_REDRAW:
			redraw_terminal_cls(term);
			break;

		case ACT_MAIN_RELOAD:
			reload(ses, CACHE_MODE_INCREMENT);
			break;

		case ACT_MAIN_RERENDER:
			draw_formatted(ses, 2);
			break;

		case ACT_MAIN_RESET_FORM:
			status = reset_form(ses, doc_view, 0);
			break;

		case ACT_MAIN_RESOURCE_INFO:
			resource_info(term);
			break;

		case ACT_MAIN_SAVE_AS:
			status = save_as(ses, doc_view, 0);
			break;

		case ACT_MAIN_SAVE_FORMATTED:
			status = save_formatted_dlg(ses, doc_view, 0);
			break;

		case ACT_MAIN_SAVE_OPTIONS:
			write_config(term);
			break;

		case ACT_MAIN_SAVE_URL_AS:
			save_url_as(ses);
			break;

		case ACT_MAIN_SCROLL_DOWN:
			status = scroll_down(ses, doc_view);
开发者ID:Efreak,项目名称:elinks,代码行数:67,代码来源:action.c


示例18: capacityMax

void Weapon::loadAmmo(std::string name, double mass) {
    m_bullet_type = name;
    m_bullet_mass = mass;
    m_capacity_current = capacityMax();
    reload();
}
开发者ID:M3237-CPP,项目名称:Deep-Space-Deathmatch,代码行数:6,代码来源:Weapon.cpp


示例19: reload

void PathWaterCallaghanAlgorithm::changeAttr(){
    this->run(coords_asked, ter);
    emit reload();
}
开发者ID:jtpefaur,项目名称:runnel,代码行数:4,代码来源:pathwatercallaghanalgorithm.cpp


示例20: iLOG


//.........这里部分代码省略.........

   bool lRetrunValue_B = false;

   for ( iDisplays const &disp : vDisplaysToChange_eD ) {
      DEVMODEW lDevmodeToChange_win32 = disp.getSelectedDevmode();

      iLOG( "Change ",
            disp.getDisplayDevice().DeviceName,
            " to: ",
            (int32_t)lDevmodeToChange_win32.dmPelsWidth,
            "x",
            (int32_t)lDevmodeToChange_win32.dmPelsHeight );
      switch ( ChangeDisplaySettingsExW(
            disp.getDisplayDevice().DeviceName,
            &lDevmodeToChange_win32,
            NULL,
            ( CDS_UPDATEREGISTRY | CDS_NORESET ), // We will apply the settings later
            NULL ) ) {
         case DISP_CHANGE_SUCCESSFUL:
            iLOG( "Successfully changed display ", disp.getDisplayDevice().DeviceName, "  [set]" );
            lRetrunValue_B = true;
            break;

         case DISP_CHANGE_BADDUALVIEW:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADDUALVIEW [set]" );
            break;

         case DISP_CHANGE_BADFLAGS:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADFLAGS [set]" );
            break;

         case DISP_CHANGE_BADMODE:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADMODE [set]" );
            break;

         case DISP_CHANGE_BADPARAM:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADPARAM [set]" );
            break;

         case DISP_CHANGE_FAILED:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_FAILED [set]" );
            break;

         case DISP_CHANGE_NOTUPDATED:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_NOTUPDATED [set]" );
            break;

         case DISP_CHANGE_RESTART:
            wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_FAILED [set] (You need to restart "
                  "yout PC because you have Windows)" );
            break;

         default: eLOG( "ChangeDisplaySettingsEx returned a unknown error [set]" ); break;
      }
   }

   // Now really apply the settings
   switch ( ChangeDisplaySettingsExW( NULL, NULL, NULL, 0, NULL ) ) {
      case DISP_CHANGE_SUCCESSFUL:
         iLOG( "Successfully applyed display changes [apply]" );
         lRetrunValue_B = true;
         break;

      case DISP_CHANGE_BADDUALVIEW:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADDUALVIEW [apply]" );
         break;

      case DISP_CHANGE_BADFLAGS:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADFLAGS [apply]" );
         break;

      case DISP_CHANGE_BADMODE:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADMODE [apply]" );
         break;

      case DISP_CHANGE_BADPARAM:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_BADPARAM [apply]" );
         break;

      case DISP_CHANGE_FAILED:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_FAILED [apply]" );
         break;

      case DISP_CHANGE_NOTUPDATED:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_NOTUPDATED [apply]" );
         break;

      case DISP_CHANGE_RESTART:
         wLOG( "ChangeDisplaySettingsEx returned DISP_CHANGE_FAILED [apply] (You need to restart "
               "yout PC because you have Windows)" );
         break;

      default: eLOG( "ChangeDisplaySettingsEx returned a unknown error [apply]" ); break;
   }

   vDisplaysToChange_eD.clear();

   reload();
   return lRetrunValue_B;
}
开发者ID:vcgato29,项目名称:engine-1,代码行数:101,代码来源:iRandR.cpp



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ relocate函数代码示例发布时间:2022-05-30
下一篇:
C++ release_spinlock函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap