/*! * * Copyright (c) 2021-2024 Diality Inc. - All Rights Reserved. * \copyright * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. * * \file VTreatmentAdjustmentFlows.cpp * \author (last) Behrouz NematiPour * \date (last) 11-Apr-2021 * \author (original) Behrouz NematiPour * \date (original) 11-Apr-2021 * */ #include "VTreatmentAdjustmentFlows.h" // Project #include "GuiController.h" VIEW_DEF_CLASS_ADJUSTMENT(VTreatmentAdjustmentFlows) void VTreatmentAdjustmentFlows::initConnections() { ACTION_VIEW_CONNECTION(AdjustBloodDialysateResponseData); ADJUST_VIEW_CONNECTION( AdjustBloodDialysateRequestData); } /*! * \brief VTreatmentAdjustmentFlows::onActionReceive * \details Model data received message handler. * When signal received this method is called to update the view properties. * \param vData - Model data */ void VTreatmentAdjustmentFlows::onActionReceive(const AdjustBloodDialysateResponseData &vData) { adjustment_Accepted ( vData.mAccepted ); adjustment_Reason ( vData.mReason ); bloodFlow_FlowSetPoint ( vData.mBloodRate ); dialysateFlow_FlowSetPoint ( vData.mDialysateRate ); // *** has to be the last to let the information to be set and then emit the signal *** // *** otherwise will use the previous values before being set. *** adjustment ( true ); }