mirror of
https://github.com/servo/servo.git
synced 2025-08-12 08:55:32 +01:00
style: Manually rename some variables.
lop is not an acceptable variable name for LengthPercentage. Differential Revision: https://phabricator.services.mozilla.com/D15813
This commit is contained in:
parent
daf1f02feb
commit
80651fde47
14 changed files with 92 additions and 92 deletions
|
@ -68,15 +68,15 @@ impl nsCSSValue {
|
|||
}
|
||||
|
||||
/// Sets LengthPercentage value to this nsCSSValue.
|
||||
pub unsafe fn set_lop(&mut self, lop: LengthPercentage) {
|
||||
if lop.was_calc {
|
||||
return bindings::Gecko_CSSValue_SetCalc(self, lop.into())
|
||||
pub unsafe fn set_length_percentage(&mut self, lp: LengthPercentage) {
|
||||
if lp.was_calc {
|
||||
return bindings::Gecko_CSSValue_SetCalc(self, lp.into())
|
||||
}
|
||||
debug_assert!(lop.percentage.is_none() || lop.unclamped_length() == Length::zero());
|
||||
if let Some(p) = lop.percentage {
|
||||
debug_assert!(lp.percentage.is_none() || lp.unclamped_length() == Length::zero());
|
||||
if let Some(p) = lp.percentage {
|
||||
return self.set_percentage(p.0);
|
||||
}
|
||||
self.set_px(lop.unclamped_length().px());
|
||||
self.set_px(lp.unclamped_length().px());
|
||||
}
|
||||
|
||||
/// Sets a px value to this nsCSSValue.
|
||||
|
@ -90,7 +90,7 @@ impl nsCSSValue {
|
|||
}
|
||||
|
||||
/// Returns LengthPercentage value.
|
||||
pub unsafe fn get_lop(&self) -> LengthPercentage {
|
||||
pub unsafe fn get_length_percentage(&self) -> LengthPercentage {
|
||||
match self.mUnit {
|
||||
nsCSSUnit::eCSSUnit_Pixel => {
|
||||
LengthPercentage::new(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue