void sheet_tracker::add_interface_trap(adobe::adam_callback_suite_t::add_interface_proc_t original,
                                       adobe::name_t cell_name, bool linked,
                                       const adobe::line_position_t& position1,
                                       const adobe::array_t& initializer,
                                       const adobe::line_position_t& position2,
                                       const adobe::array_t& expression) {
    original(cell_name, linked, position1, initializer, position2, expression, std::string(),
             std::string());

    std::cout << "A \'" << cell_name.c_str() << "\' (interface)" << std::endl;

    cell_set_m[cell_name] = adobe::any_regular_t();
}
示例#2
0
文件: main.cpp 项目: apextw/Ramen
void sheet_tracker::add_cell_trap(  adobe::adam_callback_suite_t::add_cell_proc_t   original,
                                    adobe::adam_callback_suite_t::cell_type_t       type,
                                    adobe::name_t                                   cell_name,
                                    const adobe::line_position_t&                   position,
                                    const adobe::array_t&                           expr_or_init)
{
    original(type, cell_name, position, expr_or_init, std::string(), std::string());

    std::cout << "A \'" << cell_name.c_str() << "\' (" << cell_type_to_name(type) << ")" << std::endl;

    if (cell_type_to_name(type) == adobe::static_name_t("output"))
        cell_set_m[cell_name] = adobe::any_regular_t();
}
示例#3
0
GG::StateButtonStyle name_to_style(adobe::name_t name)
{
    if (name == adobe::static_name_t("xbox"))
        return GG::SBSTYLE_3D_XBOX;
    else if (name == adobe::static_name_t("checkbox"))
        return GG::SBSTYLE_3D_CHECKBOX;
    else if (name == adobe::static_name_t("radio"))
        return GG::SBSTYLE_3D_RADIO;
    else if (name == adobe::static_name_t("button"))
        return GG::SBSTYLE_3D_BUTTON;
    else if (name == adobe::static_name_t("round_button"))
        return GG::SBSTYLE_3D_ROUND_BUTTON;
    else if (name == adobe::static_name_t("top_attached_tab"))
        return GG::SBSTYLE_3D_TOP_ATTACHED_TAB;
    else if (name == adobe::static_name_t("top_detached_tab"))
        return GG::SBSTYLE_3D_TOP_DETACHED_TAB;
    else throw std::runtime_error(adobe::make_string("Unknown StateButtonStyle name ", name.c_str()));
}