Fix ubuntu 16.04 macbook brightness issue after lid close

Note: All tests are being done on 2013 macbook air

Ubuntu on MacBook almost works perfectly like any other laptops out there. There are some issues though. One the most annoying one is the brightness issue. Once the lid is closed, it goes to sleep state. After waking up, only 2 options for the brightness 0 or 100.

To solve the issue we need to install mba6x_bl

Follow the following steps

╰─○ git clone git://github.com/patjak/mba6x_bl 
╰─○ cd mba6x_bl 
╰─○ make
╰─○ checkinstall
╰─○ sudo dpkg -i mba6x-bl_xxxxxx_amd64.deb (check your folder for the exact name of deb file generated from check install)
╰─○ sudo depmod -a 
╰─○ sudo modprobe mba6x_bl 
╰─○ sudo reboot

That’s it folks. You have successfully squashed the bug

Enjoy smile

Clear values inside bootstrap modal upon closing

I don’t know whether this is going to be useful for anyone. Since i wanted to share something in the site after a long time, i am putting things. I will be regular now on wink (i hope so)

 


$('#mymodal').on('hidden.bs.modal', function() {
$(this)
.find("input,textarea,select")
.val('')
.end()
.find("input[type=checkbox], input[type=radio]")
.prop("checked", "")
.end();
})

Njoy smile