Macros to eliminate 'f + 0.0' (#21568)
This commit is contained in:
@ -269,7 +269,7 @@ static inline void _lcd_level_bed_corners_get_next_position() {
|
||||
do {
|
||||
ui.refresh(LCDVIEW_REDRAW_NOW);
|
||||
_lcd_draw_probing(); // update screen with # of good points
|
||||
do_blocking_move_to_z(current_position.z + LEVEL_CORNERS_Z_HOP + TERN0(BLTOUCH_HS_MODE, 7)); // clearance
|
||||
do_blocking_move_to_z(SUM_TERN(BLTOUCH_HS_MODE, current_position.z + LEVEL_CORNERS_Z_HOP, 7)); // clearance
|
||||
|
||||
_lcd_level_bed_corners_get_next_position(); // Select next corner coordinates
|
||||
current_position -= probe.offset_xy; // Account for probe offsets
|
||||
|
@ -93,7 +93,7 @@ static void _lcd_move_xyz(PGM_P const name, const AxisEnum axis) {
|
||||
ui.encoderPosition = 0;
|
||||
if (ui.should_draw()) {
|
||||
const float pos = NATIVE_TO_LOGICAL(
|
||||
ui.manual_move.processing ? destination[axis] : current_position[axis] + TERN0(IS_KINEMATIC, ui.manual_move.offset),
|
||||
ui.manual_move.processing ? destination[axis] : SUM_TERN(IS_KINEMATIC, current_position[axis], ui.manual_move.offset),
|
||||
axis
|
||||
);
|
||||
if (parser.using_inch_units()) {
|
||||
@ -130,8 +130,8 @@ void lcd_move_z() { _lcd_move_xyz(GET_TEXT(MSG_MOVE_Z), Z_AXIS); }
|
||||
MenuEditItemBase::draw_edit_screen(
|
||||
GET_TEXT(TERN(MULTI_MANUAL, MSG_MOVE_EN, MSG_MOVE_E)),
|
||||
ftostr41sign(current_position.e
|
||||
+ TERN0(IS_KINEMATIC, ui.manual_move.offset)
|
||||
- TERN0(MANUAL_E_MOVES_RELATIVE, manual_move_e_origin)
|
||||
PLUS_TERN0(IS_KINEMATIC, ui.manual_move.offset)
|
||||
MINUS_TERN0(MANUAL_E_MOVES_RELATIVE, manual_move_e_origin)
|
||||
)
|
||||
);
|
||||
} // should_draw
|
||||
|
@ -610,7 +610,7 @@ static void drawAxisValue(AxisEnum axis) {
|
||||
probe.offset.z :
|
||||
#endif
|
||||
NATIVE_TO_LOGICAL(
|
||||
ui.manual_move.processing ? destination[axis] : current_position[axis] + TERN0(IS_KINEMATIC, ui.manual_move.offset),
|
||||
ui.manual_move.processing ? destination[axis] : SUM_TERN(IS_KINEMATIC, current_position[axis], ui.manual_move.offset),
|
||||
axis
|
||||
);
|
||||
xy_int_t pos;
|
||||
|
Reference in New Issue
Block a user