Both T1 and T2 have some genetic basis but not the same genes so as far as we know they are not related.
There are many genes that have been associated with T2 Its estimated 30-70% of the type 2 diabetes risk can be attributed to genes. The rest is considered to be environmental.
Around 40 genes have been discovered that may predispose or protect from T2.eg one of these genes is the TCF7L2 gene. This is associated with impaired insulin production and increased glucose production from the liver. Someone with 1 copy of the gene has a 1.5x increased risk of diabetes and a 2.4x risk with 2 copies. Some genes are more likely to be found in some ethnic groups than others.
T2 in some ways has a stronger genetic basis than T1 . If one twin gets T2 then the 2nd has a relatively high risk of developing it.
Type 1a is an autoimmune disease. The genes that code for proteins that play a role in the immune system are the HLA genes. There are several variants of this gene and some variants protect but some variants lead to a predisposition to Type 1 diabetes and other autoimmune conditions. (eg HLA-DRB1 is associated with both T1 and autoimmune thyroid disease) Having a particular gene variant though doesn't mean you will develop T1 , there will be some environmental trigger that sets it off (and what that or they are is very much debated)
(interestingly it might all be because an ancestor mated with a roving Neanderthal !)
http://www.theguardian.com/science/blog ... n-immunity
There are then some rarer types of diabetes that are neither T1 nor T2 and are are absolutely genetic conditions. One of these is MODY which is caused by a gene mutation . There are several types of MODY gene mutations that have been discovered . Some of the mutations cause a defect in insulin secretion and one of them causes a defect in the storage of glucose in the liver.
If you nave one of these types of diabetes your child will have a 50% chance of inheriting it.
Type 2 genes pdf
Type 1 info
http://ghr.nlm.nih.gov/condition/type-1-diabetes
Huge Tome about the genetics of diabetes (very detailed but 2004 so not up to date with recent findings eg there have been many more T2 and MODY genes found since it was written)
http://www.ncbi.nlm.nih.gov/books/NBK1667/?depth=1