Re: [tim-janik/beast] Bus properties ported to C++ - redone with APPLY_IDL_PROPERTY() macro (#105)



@swesterfeld commented on this pull request.


In bse/bsebus.cc:

> @@ -1003,6 +993,25 @@ BusImpl::BusImpl (BseObject *bobj) :
 BusImpl::~BusImpl ()
 {}
 
+bool
+BusImpl::mute() const
+{
+  BseBus *self = const_cast<BusImpl*> (this)->as<BseBus*>();
+
+  return self->muted;
+}
+
+void
+BusImpl::mute (bool val)
+{
+  BseBus *self = const_cast<BusImpl*> (this)->as<BseBus*>();
+
+  if (APPLY_IDL_PROPERTY (self->muted, val))
+    {

Ok, the lines caused by { } are not really necessary, so I removed then. I'd still like to keep a blank line between BseBus *self and the rest of the code. Obviously "readability" is not an objective criterium but depends on the coder reading the code. But for me, the extra blank line makes the code more readable. I often use blank lines to seperate code in groups that belong together. And we're no longer coding with 80x24 terminals, so we have space for many lines on the screen.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]