1
Vote

Suggested bugfix

description

Hi, I just discovered your control and it is rather impressive. In my attempts to integrate it I bumped into a litlle bug: in ImageButtonFactroy.CreateImageButton, line 35, there is this expression:
if (_contentTabView.Views.TryGetValue(view, out title))
{
     imageButton.Title = title.ToString();
}
I suggest you rather write this:
if (_contentTabView.Views.TryGetValue(view, out title))
{
    if (title == null)
        imageButton.Title = string.Empty;
    else imageButton.Title = title.ToString();
}
This avoids a NullReferenceException when title is not initialized (as was the case in my first tests).

Hope this helps.

comments

adajos wrote May 1, 2013 at 8:27 PM

Hi,

I'm not actively working on this control anymore. Thanks for the tip though. I've actually moved this to github: https://github.com/adajos/FabTab

Feel free to fork my repo and submit a pull request with your change and i will accept it.

Thanks,

Josh

odalet wrote May 2, 2013 at 7:29 AM

OK, I'll do that. Thanks.