# # # patch "cset.hh" # from [5a205be4ade4d652ad3a689a13f8a3fb86767d0d] # to [90ea3f1a13761e0b3bd3ec3c894f7b91feb4a4c6] # # patch "roster.cc" # from [66bc35b83523f6e54dfb1d33ca1a747a867779f8] # to [ff3e7002de0ea5cded215d2f90e6f399386a793d] # # patch "roster.hh" # from [26bb4cf4733b6ffe738f39e063d9dfcfdaabe08a] # to [f79fe7c3e150abe91f2497421a71eacbd0145d60] # # patch "work.cc" # from [7d826f4bcafad857185c2a1d81a3c3ab1fcaff66] # to [269f9057c546abfb57d5adb516731b40ef0884e8] # ============================================================ --- cset.hh 5a205be4ade4d652ad3a689a13f8a3fb86767d0d +++ cset.hh 90ea3f1a13761e0b3bd3ec3c894f7b91feb4a4c6 @@ -33,10 +33,10 @@ struct editable_tree virtual void apply_delta(file_path const & pth, file_id const & old_id, file_id const & new_id) = 0; - virtual void clear_attr(file_path const & pth, - attr_key const & name) = 0; - virtual void set_attr(file_path const & pth, - attr_key const & name, + virtual void clear_attr(file_path const & path, + attr_key const & key) = 0; + virtual void set_attr(file_path const & path, + attr_key const & key, attr_value const & val) = 0; virtual void commit() = 0; ============================================================ --- roster.cc 66bc35b83523f6e54dfb1d33ca1a747a867779f8 +++ roster.cc ff3e7002de0ea5cded215d2f90e6f399386a793d @@ -934,10 +934,10 @@ void void -roster_t::clear_attr(file_path const & pth, - attr_key const & name) +roster_t::clear_attr(file_path const & path, + attr_key const & key) { - set_attr(pth, name, make_pair(false, attr_value())); + set_attr(path, key, make_pair(false, attr_value())); } void @@ -949,11 +949,11 @@ void } void -roster_t::set_attr(file_path const & pth, - attr_key const & name, +roster_t::set_attr(file_path const & path, + attr_key const & key, attr_value const & val) { - set_attr(pth, name, make_pair(true, val)); + set_attr(path, key, make_pair(true, val)); } @@ -1179,20 +1179,20 @@ void } void -editable_roster_base::clear_attr(file_path const & pth, - attr_key const & name) +editable_roster_base::clear_attr(file_path const & path, + attr_key const & key) { - // L(FL("clear_attr('%s', '%s')") % pth % name); - r.clear_attr(pth, name); + // L(FL("clear_attr('%s', '%s')") % path % key); + r.clear_attr(path, key); } void -editable_roster_base::set_attr(file_path const & pth, - attr_key const & name, +editable_roster_base::set_attr(file_path const & path, + attr_key const & key, attr_value const & val) { - // L(FL("set_attr('%s', '%s', '%s')") % pth % name % val); - r.set_attr(pth, name, val); + // L(FL("set_attr('%s', '%s', '%s')") % path % key % val); + r.set_attr(path, key, val); } void @@ -1742,17 +1742,17 @@ namespace { marking->second.file_content.insert(rid); } - virtual void clear_attr(file_path const & pth, attr_key const & name) + virtual void clear_attr(file_path const & path, attr_key const & key) { - this->editable_roster_base::clear_attr(pth, name); - handle_attr(pth, name); + this->editable_roster_base::clear_attr(path, key); + handle_attr(path, key); } - virtual void set_attr(file_path const & pth, attr_key const & name, + virtual void set_attr(file_path const & path, attr_key const & key, attr_value const & val) { - this->editable_roster_base::set_attr(pth, name, val); - handle_attr(pth, name); + this->editable_roster_base::set_attr(path, key, val); + handle_attr(path, key); } node_id handle_new(node_id nid) ============================================================ --- roster.hh 26bb4cf4733b6ffe738f39e063d9dfcfdaabe08a +++ roster.hh f79fe7c3e150abe91f2497421a71eacbd0145d60 @@ -178,13 +178,13 @@ public: void apply_delta(file_path const & pth, file_id const & old_id, file_id const & new_id); - void clear_attr(file_path const & pth, - attr_key const & name); - void set_attr(file_path const & pth, - attr_key const & name, + void clear_attr(file_path const & path, + attr_key const & key); + void set_attr(file_path const & path, + attr_key const & key, attr_value const & val); - void set_attr(file_path const & pth, - attr_key const & name, + void set_attr(file_path const & path, + attr_key const & key, std::pair const & val); // more direct, lower-level operations, for the use of roster_delta's @@ -298,10 +298,10 @@ public: virtual void apply_delta(file_path const & pth, file_id const & old_id, file_id const & new_id); - virtual void clear_attr(file_path const & pth, - attr_key const & name); - virtual void set_attr(file_path const & pth, - attr_key const & name, + virtual void clear_attr(file_path const & path, + attr_key const & key); + virtual void set_attr(file_path const & path, + attr_key const & key, attr_value const & val); virtual void commit(); protected: ============================================================ --- work.cc 7d826f4bcafad857185c2a1d81a3c3ab1fcaff66 +++ work.cc 269f9057c546abfb57d5adb516731b40ef0884e8 @@ -955,10 +955,10 @@ struct editable_working_tree : public ed virtual void apply_delta(file_path const & pth, file_id const & old_id, file_id const & new_id); - virtual void clear_attr(file_path const & pth, - attr_key const & name); - virtual void set_attr(file_path const & pth, - attr_key const & name, + virtual void clear_attr(file_path const & path, + attr_key const & key); + virtual void set_attr(file_path const & path, + attr_key const & key, attr_value const & val); virtual void commit(); @@ -996,10 +996,10 @@ struct simulated_working_tree : public e virtual void apply_delta(file_path const & pth, file_id const & old_id, file_id const & new_id); - virtual void clear_attr(file_path const & pth, - attr_key const & name); - virtual void set_attr(file_path const & pth, - attr_key const & name, + virtual void clear_attr(file_path const & path, + attr_key const & key); + virtual void set_attr(file_path const & path, + attr_key const & key, attr_value const & val); virtual void commit(); @@ -1189,16 +1189,16 @@ void } void -editable_working_tree::clear_attr(file_path const & pth, - attr_key const & name) +editable_working_tree::clear_attr(file_path const & path, + attr_key const & key) { // FIXME_ROSTERS: call a lua hook } void -editable_working_tree::set_attr(file_path const & pth, - attr_key const & name, - attr_value const & val) +editable_working_tree::set_attr(file_path const & path, + attr_key const & key, + attr_value const & value) { // FIXME_ROSTERS: call a lua hook } @@ -1299,14 +1299,14 @@ void } void -simulated_working_tree::clear_attr(file_path const & pth, - attr_key const & name) +simulated_working_tree::clear_attr(file_path const & path, + attr_key const & key) { } void -simulated_working_tree::set_attr(file_path const & pth, - attr_key const & name, +simulated_working_tree::set_attr(file_path const & path, + attr_key const & key, attr_value const & val) { } @@ -1876,8 +1876,7 @@ workspace::update_any_attrs(database & d for (attr_map_t::const_iterator j = n->attrs.begin(); j != n->attrs.end(); ++j) if (j->second.first) - lua.hook_apply_attribute(j->first(), fp, - j->second.second()); + lua.hook_apply_attribute(j->first(), fp, j->second.second()); } }