Unverified Commit ae4fa610 authored by Murray Cumming's avatar Murray Cumming
Browse files

Document: Minor const improvements.

parent 7a2f0f05
......@@ -676,7 +676,7 @@ void Document::remove_relationship(const std::shared_ptr<const Relationship>& re
}
//Remove relationship from any layouts:
auto layouts = info->m_layouts;
const auto& layouts = info->m_layouts;
auto iterLayouts = layouts.begin();
while(iterLayouts != layouts.end())
{
......@@ -942,7 +942,7 @@ void Document::change_field_name(const Glib::ustring& table_name, const Glib::us
if(info)
{
//Fields:
type_vec_fields& vecFields = info->m_fields;
const auto& vecFields = info->m_fields;
auto iterFind = find_if_same_name(vecFields, strFieldNameOld);
if(iterFind != vecFields.end()) //If it was found:
{
......@@ -1519,7 +1519,7 @@ Document::type_list_layout_groups Document::get_data_layout_groups(const Glib::u
const std::shared_ptr<const DocumentTableInfo> info = get_table_info(parent_table_name);
if(info)
{
const DocumentTableInfo::type_layouts layouts = info->m_layouts;
const auto& layouts = info->m_layouts;
//Look for the layout with this name:
auto iter = find_if_layout(layouts, layout_name, layout_platform);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment